mvneta: Try to fix mvneta when compiled as module
authorArnaud Patard \(Rtp\) <arnaud.patard@rtp-net.org>
Mon, 29 Jul 2013 19:56:48 +0000 (21:56 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 31 Jul 2013 02:32:36 +0000 (19:32 -0700)
commit5445eaf309ff2868c77354016505fc7315947a35
treee781a2e6b62715e3ff0e125182681f7be0b946fc
parentaded09555b7a0748a692d0d644ac54c10c1c0757
mvneta: Try to fix mvneta when compiled as module

When the mvneta driver is compiled as module, the clock is disabled before
it's loading. This will reset the registers values and all configuration
made by the bootloader.

This patch sets the "sgmii serdes configuration" register to a magical value
found in:
https://github.com/yellowback/ubuntu-precise-armadaxp/blob/master/arch/arm/mach-armadaxp/armada_xp_family/ctrlEnv/mvCtrlEnvLib.c

With this change, the interrupts are working/generated and ethernet is
working.

Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvneta.c