diff options
| author | Sandeep Paulraj <[email protected]> | 2010-12-28 14:37:33 -0500 |
|---|---|---|
| committer | Albert Aribaud <[email protected]> | 2011-02-02 00:54:44 +0100 |
| commit | 4b9b9e7c665bfcff43bc720b579b6b03a5078736 (patch) | |
| tree | 2754915ca87c86350823d94ede61f27475be700f | |
| parent | 99e4c7546357c824a7435d531ca7eb570a755376 (diff) | |
DaVinci EMAC: Fix davinci_eth_gigabit_enable
Enabling the gigabit was overwriting the
previous configuration by setting up only GIGAFORCE and
GIG bits of MAC control register.
Modified to retain previous configuration while
gigabit enabling.
Signed-off-by: Prakash PM <[email protected]>
Signed-off-by: Sandeep Paulraj <[email protected]>
| -rw-r--r-- | drivers/net/davinci_emac.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/davinci_emac.c b/drivers/net/davinci_emac.c index 56cd2aaf492..2642a5aaf0d 100644 --- a/drivers/net/davinci_emac.c +++ b/drivers/net/davinci_emac.c @@ -322,9 +322,10 @@ static void __attribute__((unused)) davinci_eth_gigabit_enable(void) * Check if link detected is giga-bit * If Gigabit mode detected, enable gigbit in MAC */ - writel(EMAC_MACCONTROL_GIGFORCE | - EMAC_MACCONTROL_GIGABIT_ENABLE, - &adap_emac->MACCONTROL); + writel(readl(&adap_emac->MACCONTROL) | + EMAC_MACCONTROL_GIGFORCE | + EMAC_MACCONTROL_GIGABIT_ENABLE, + &adap_emac->MACCONTROL); } } } |
