Пример #1
0
void hieth_sys_reset(void)
{
    SFE_OFF;
//	hieth_reset(1);
	hieth_reset(0);
    SFL;
}
Пример #2
0
void hieth_sys_init(void)
{
	hieth_funsel_config();
	hieth_sys_allstop();
	hieth_reset(0);
	hieth_clk_ena();
	udelay(10000);
	hieth_phy_reset();
}
Пример #3
0
void hieth_sys_init(void)
{
	hieth_funsel_config();
	hieth_sys_allstop();
	hieth_phy_reset();
	hieth_clk_ena();
	hieth_reset(0);
	revise_led_shine();
}
Пример #4
0
void hieth_sys_init(void)
{
    SFE_OFF;

#if 0
	/* enable mdio clk */
	unsigned int val = _readl(HIETH_SYSREG_BASE + ETH_X5V100_MDIO_CLK_EN);
	_writel(val | (1<<26), HIETH_SYSREG_BASE + ETH_X5V100_MDIO_CLK_EN);
#endif

#ifdef HISFV_RESET_GPIO_EN
	unsigned int val = 0;
    /*gpiox[x] reset*/
    /*first reset,then delay 200ms*/
	val = __raw_readw(HISFV_RESET_GPIO_BASE + HISFV_RESET_GPIO_DIR);
	val |= (HISFV_RESET_GPIO_DIR_OUT << HISFV_RESET_GPIO_BIT);
	__raw_writew(val,HISFV_RESET_GPIO_BASE + HISFV_RESET_GPIO_DIR);
    __raw_writew(HISFV_RESET_GPIO_DATA, HISFV_RESET_GPIO_BASE + (4 << HISFV_RESET_GPIO_BIT));

    udelay(200000);

    /*then,cancel reset,and should delay 200ms*/
	val = __raw_readw(HISFV_RESET_GPIO_BASE + HISFV_RESET_GPIO_DIR);
	val |= (HISFV_RESET_GPIO_DIR_OUT << HISFV_RESET_GPIO_BIT);
	__raw_writew(val,HISFV_RESET_GPIO_BASE + HISFV_RESET_GPIO_DIR);
    __raw_writew(((!HISFV_RESET_GPIO_DATA) << HISFV_RESET_GPIO_BIT), HISFV_RESET_GPIO_BASE + (4 << HISFV_RESET_GPIO_BIT));

	udelay(20000);
#endif
//	function_sel = _readl(HIETH_SYSREG_BASE + REG_FUNC_SEL);

//	hieth_reset(1);
//	hieth_function_sel(0, 1);
	hieth_clk_ena();
	hieth_reset(0);
    SFL;
}
Пример #5
0
void hieth_sys_startup(void)
{
	hieth_clk_ena();
	/* undo reset */
	hieth_reset(0);
}