提交 50128fe8 编写于 作者: J John Crispin 提交者: Ralf Baechle

MIPS: lantiq: reboot gphy on restart

A reboot sometimes lead to a none working phy. An explicit reboot fixes the
problem.
Signed-off-by: NJohn Crispin <blogic@openwrt.org>
Patchwork: http://patchwork.linux-mips.org/patch/8044/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
上级 c530781c
......@@ -176,8 +176,15 @@ void ltq_rst_init(void)
static void ltq_machine_restart(char *command)
{
u32 val = ltq_rcu_r32(RCU_RST_REQ);
if (of_device_is_compatible(ltq_rcu_np, "lantiq,rcu-xrx200"))
val |= RCU_RD_GPHY1_XRX200 | RCU_RD_GPHY0_XRX200;
val |= RCU_RD_SRST;
local_irq_disable();
ltq_rcu_w32(ltq_rcu_r32(RCU_RST_REQ) | RCU_RD_SRST, RCU_RST_REQ);
ltq_rcu_w32(val, RCU_RST_REQ);
unreachable();
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册