From: Andrea Merello Date: Wed, 26 Mar 2014 20:00:42 +0000 (+0100) Subject: rtl8180: don't write MAR registers for rtl8187se X-Git-Tag: firefly_0821_release~176^2~4167^2~18^2^2~22 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=f18f112bde931faa25b33f7fa97281be5ef5e2c4;p=firefly-linux-kernel-4.4.55.git rtl8180: don't write MAR registers for rtl8187se MAR registers are not present in rtl8187se, and attempting to write to them must be avoided Signed-off-by: Andrea Merello Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/rtl818x/rtl8180/dev.c b/drivers/net/wireless/rtl818x/rtl8180/dev.c index 92b6d53ca0ef..cce972d289ef 100644 --- a/drivers/net/wireless/rtl818x/rtl8180/dev.c +++ b/drivers/net/wireless/rtl818x/rtl8180/dev.c @@ -779,8 +779,13 @@ static int rtl8180_start(struct ieee80211_hw *dev) rtl8180_int_enable(dev); - rtl818x_iowrite32(priv, &priv->map->MAR[0], ~0); - rtl818x_iowrite32(priv, &priv->map->MAR[1], ~0); + /* in rtl8187se at MAR regs offset there is the management + * TX descriptor DMA addres.. + */ + if (priv->chip_family != RTL818X_CHIP_FAMILY_RTL8187SE) { + rtl818x_iowrite32(priv, &priv->map->MAR[0], ~0); + rtl818x_iowrite32(priv, &priv->map->MAR[1], ~0); + } reg = RTL818X_RX_CONF_ONLYERLPKT | RTL818X_RX_CONF_RX_AUTORESETPHY |