staging: rtl8187se: Fixed size of BEACON_INTERVAL register
authorMaxim Mikityanskiy <maxtram95@gmail.com>
Tue, 13 Nov 2012 17:28:22 +0000 (19:28 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 13 Nov 2012 20:41:59 +0000 (12:41 -0800)
BEACON_INTERVAL register is 16-bit, not 32-bit

Signed-off-by: Maxim Mikityanskiy <maxtram95@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8187se/r8180_core.c

index 73a6994746f089e3d01a1f23eae98fff7b6ae995..ea04eec3095247ded8ad6597cb08b9ba44e90427 100644 (file)
@@ -1984,10 +1984,10 @@ void rtl8180_link_change(struct net_device *dev)
        write_nic_dword(dev, BSSID, ((u32 *)net->bssid)[0]);
        write_nic_word(dev, BSSID+4, ((u16 *)net->bssid)[2]);
 
-       beacon_interval  = read_nic_dword(dev, BEACON_INTERVAL);
+       beacon_interval  = read_nic_word(dev, BEACON_INTERVAL);
        beacon_interval &= ~BEACON_INTERVAL_MASK;
        beacon_interval |= net->beacon_interval;
-       write_nic_dword(dev, BEACON_INTERVAL, beacon_interval);
+       write_nic_word(dev, BEACON_INTERVAL, beacon_interval);
 
        rtl8180_set_mode(dev, EPROM_CMD_NORMAL);