mirror of
				https://source.denx.de/u-boot/u-boot.git
				synced 2025-11-04 10:21:25 +01:00 
			
		
		
		
	Merge git://git.denx.de/u-boot-sunxi
This commit is contained in:
		
						commit
						66bd5a3ebb
					
				@ -217,6 +217,8 @@ int board_init(void)
 | 
				
			|||||||
	satapwr_pin = sunxi_name_to_gpio(CONFIG_SATAPWR);
 | 
						satapwr_pin = sunxi_name_to_gpio(CONFIG_SATAPWR);
 | 
				
			||||||
	gpio_request(satapwr_pin, "satapwr");
 | 
						gpio_request(satapwr_pin, "satapwr");
 | 
				
			||||||
	gpio_direction_output(satapwr_pin, 1);
 | 
						gpio_direction_output(satapwr_pin, 1);
 | 
				
			||||||
 | 
						/* Give attached sata device time to power-up to avoid link timeouts */
 | 
				
			||||||
 | 
						mdelay(500);
 | 
				
			||||||
#endif
 | 
					#endif
 | 
				
			||||||
#ifdef CONFIG_MACPWR
 | 
					#ifdef CONFIG_MACPWR
 | 
				
			||||||
	macpwr_pin = sunxi_name_to_gpio(CONFIG_MACPWR);
 | 
						macpwr_pin = sunxi_name_to_gpio(CONFIG_MACPWR);
 | 
				
			||||||
 | 
				
			|||||||
@ -604,6 +604,8 @@ static void sun8i_emac_board_setup(struct emac_eth_dev *priv)
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
	struct sunxi_ccm_reg *ccm = (struct sunxi_ccm_reg *)SUNXI_CCM_BASE;
 | 
						struct sunxi_ccm_reg *ccm = (struct sunxi_ccm_reg *)SUNXI_CCM_BASE;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#ifdef CONFIG_MACH_SUNXI_H3_H5
 | 
				
			||||||
 | 
						/* Only H3/H5 have clock controls for internal EPHY */
 | 
				
			||||||
	if (priv->use_internal_phy) {
 | 
						if (priv->use_internal_phy) {
 | 
				
			||||||
		/* Set clock gating for ephy */
 | 
							/* Set clock gating for ephy */
 | 
				
			||||||
		setbits_le32(&ccm->bus_gate4, BIT(AHB_GATE_OFFSET_EPHY));
 | 
							setbits_le32(&ccm->bus_gate4, BIT(AHB_GATE_OFFSET_EPHY));
 | 
				
			||||||
@ -611,6 +613,7 @@ static void sun8i_emac_board_setup(struct emac_eth_dev *priv)
 | 
				
			|||||||
		/* Deassert EPHY */
 | 
							/* Deassert EPHY */
 | 
				
			||||||
		setbits_le32(&ccm->ahb_reset2_cfg, BIT(AHB_RESET_OFFSET_EPHY));
 | 
							setbits_le32(&ccm->ahb_reset2_cfg, BIT(AHB_RESET_OFFSET_EPHY));
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					#endif
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	/* Set clock gating for emac */
 | 
						/* Set clock gating for emac */
 | 
				
			||||||
	setbits_le32(&ccm->ahb_gate0, BIT(AHB_GATE_OFFSET_GMAC));
 | 
						setbits_le32(&ccm->ahb_gate0, BIT(AHB_GATE_OFFSET_GMAC));
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user