rt2x00: Always set BBP_CSR_CFG_BBP_RW_MODE to 1
authorIvo van Doorn <IvDoorn@gmail.com>
Tue, 29 Jun 2010 19:49:26 +0000 (21:49 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 30 Jun 2010 19:00:53 +0000 (15:00 -0400)
Latest rt2870 legacy driver also sets BBP_CSR_CFG_BBP_RW_MODE to 1
when reading or writing the EEPROM. This means we can make the
BBP reading and writing completely equal on all platforms.

Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rt2x00/rt2800lib.c

index 0cf7796cdff52889dc3306bd5c147429e5186d10..f813b4388b63774a416e5291f519ebebb98e9ab2 100644 (file)
@@ -99,8 +99,7 @@ static void rt2800_bbp_write(struct rt2x00_dev *rt2x00dev,
                rt2x00_set_field32(&reg, BBP_CSR_CFG_REGNUM, word);
                rt2x00_set_field32(&reg, BBP_CSR_CFG_BUSY, 1);
                rt2x00_set_field32(&reg, BBP_CSR_CFG_READ_CONTROL, 0);
-               if (rt2x00_is_pci(rt2x00dev) || rt2x00_is_soc(rt2x00dev))
-                       rt2x00_set_field32(&reg, BBP_CSR_CFG_BBP_RW_MODE, 1);
+               rt2x00_set_field32(&reg, BBP_CSR_CFG_BBP_RW_MODE, 1);
 
                rt2800_register_write_lock(rt2x00dev, BBP_CSR_CFG, reg);
        }
@@ -128,8 +127,7 @@ static void rt2800_bbp_read(struct rt2x00_dev *rt2x00dev,
                rt2x00_set_field32(&reg, BBP_CSR_CFG_REGNUM, word);
                rt2x00_set_field32(&reg, BBP_CSR_CFG_BUSY, 1);
                rt2x00_set_field32(&reg, BBP_CSR_CFG_READ_CONTROL, 1);
-               if (rt2x00_is_pci(rt2x00dev) || rt2x00_is_soc(rt2x00dev))
-                       rt2x00_set_field32(&reg, BBP_CSR_CFG_BBP_RW_MODE, 1);
+               rt2x00_set_field32(&reg, BBP_CSR_CFG_BBP_RW_MODE, 1);
 
                rt2800_register_write_lock(rt2x00dev, BBP_CSR_CFG, reg);