rt2x00: Unify GPIO register field namings
The various rt2x00 drivers use different methods to name the different GPIO register fields indicating the GPIO pin value and the fields indicating the direction. Start using a unified naming scheme for the GPIO register fields: - <csr>_VAL<x> for fields indicating the GPIO pin value. - <csr>_DIR<x> for fields indicating the GPIO pin direction. Signed-off-by: Gertjan van Wingerde <gwingerde@gmail.com> Acked-by: Ivo Van Doorn <ivdoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:

committed by
John W. Linville

parent
605b55186b
commit
99bdf51a68
@@ -283,7 +283,7 @@ static int rt2500usb_rfkill_poll(struct rt2x00_dev *rt2x00dev)
|
||||
u16 reg;
|
||||
|
||||
rt2500usb_register_read(rt2x00dev, MAC_CSR19, ®);
|
||||
return rt2x00_get_field16(reg, MAC_CSR19_BIT7);
|
||||
return rt2x00_get_field16(reg, MAC_CSR19_VAL7);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_RT2X00_LIB_LEDS
|
||||
@@ -1786,7 +1786,7 @@ static int rt2500usb_probe_hw(struct rt2x00_dev *rt2x00dev)
|
||||
* rfkill switch GPIO pin correctly.
|
||||
*/
|
||||
rt2500usb_register_read(rt2x00dev, MAC_CSR19, ®);
|
||||
rt2x00_set_field16(®, MAC_CSR19_BIT8, 0);
|
||||
rt2x00_set_field16(®, MAC_CSR19_DIR0, 0);
|
||||
rt2500usb_register_write(rt2x00dev, MAC_CSR19, reg);
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user