From: Jiri Slaby <jirislaby@xxxxxxxxx> We need to use driver_data for more than pin and polaroty data. Remove driver_data designator from ATH_LED definition and write it explicitly. Signed-off-by: Jiri Slaby <jirislaby@xxxxxxxxx> --- drivers/net/wireless/ath/ath5k/led.c | 33 +++++++++++++++++++++------------ 1 files changed, 21 insertions(+), 12 deletions(-) diff --git a/drivers/net/wireless/ath/ath5k/led.c b/drivers/net/wireless/ath/ath5k/led.c index 762e40d..0374b1f 100644 --- a/drivers/net/wireless/ath/ath5k/led.c +++ b/drivers/net/wireless/ath/ath5k/led.c @@ -47,30 +47,39 @@ .vendor = PCI_ANY_ID, .device = PCI_ANY_ID, \ .subvendor = (subv), .subdevice = (subd) -#define ATH_LED(pin,polarity) .driver_data = (((pin) << 8) | (polarity)) -#define ATH_PIN(data) ((data) >> 8) -#define ATH_POLARITY(data) ((data) & 0xff) +#define ATH_LED(pin, polarity) (((pin) << 8) | (polarity)) +#define ATH_PIN(data) (((data) >> 8) & 0xffff) +#define ATH_POLARITY(data) ((data) & 0xff) /* Devices we match on for LED config info (typically laptops) */ static const struct pci_device_id ath5k_led_devices[] = { /* AR5211 */ - { PCI_VDEVICE(ATHEROS, PCI_DEVICE_ID_ATHEROS_AR5211), ATH_LED(0, 0) }, + { PCI_VDEVICE(ATHEROS, PCI_DEVICE_ID_ATHEROS_AR5211), + .driver_data = ATH_LED(0, 0) }, /* HP Compaq nc6xx, nc4000, nx6000 */ - { ATH_SDEVICE(PCI_VENDOR_ID_COMPAQ, PCI_ANY_ID), ATH_LED(1, 1) }, + { ATH_SDEVICE(PCI_VENDOR_ID_COMPAQ, PCI_ANY_ID), + .driver_data = ATH_LED(1, 1) }, /* Acer Aspire One A150 (maximlevitsky@xxxxxxxxx) */ - { ATH_SDEVICE(PCI_VENDOR_ID_FOXCONN, 0xe008), ATH_LED(3, 0) }, + { ATH_SDEVICE(PCI_VENDOR_ID_FOXCONN, 0xe008), + .driver_data = ATH_LED(3, 0) }, /* Acer Ferrari 5000 (russ.dill@xxxxxxxxx) */ - { ATH_SDEVICE(PCI_VENDOR_ID_AMBIT, 0x0422), ATH_LED(1, 1) }, + { ATH_SDEVICE(PCI_VENDOR_ID_AMBIT, 0x0422), + .driver_data = ATH_LED(1, 1) }, /* E-machines E510 (tuliom@xxxxxxxxx) */ - { ATH_SDEVICE(PCI_VENDOR_ID_AMBIT, 0x0428), ATH_LED(3, 0) }, + { ATH_SDEVICE(PCI_VENDOR_ID_AMBIT, 0x0428), + .driver_data = ATH_LED(3, 0) }, /* Acer Extensa 5620z (nekoreeve@xxxxxxxxx) */ - { ATH_SDEVICE(PCI_VENDOR_ID_QMI, 0x0105), ATH_LED(3, 0) }, + { ATH_SDEVICE(PCI_VENDOR_ID_QMI, 0x0105), + .driver_data = ATH_LED(3, 0) }, /* Fukato Datacask Jupiter 1014a (mrb74@xxxxxx) */ - { ATH_SDEVICE(PCI_VENDOR_ID_AZWAVE, 0x1026), ATH_LED(3, 0) }, + { ATH_SDEVICE(PCI_VENDOR_ID_AZWAVE, 0x1026), + .driver_data = ATH_LED(3, 0) }, /* IBM ThinkPad AR5BXB6 (legovini@xxxxxxxxxxxxxxxxxxxxx) */ - { ATH_SDEVICE(PCI_VENDOR_ID_IBM, 0x058a), ATH_LED(1, 0) }, + { ATH_SDEVICE(PCI_VENDOR_ID_IBM, 0x058a), + .driver_data = ATH_LED(1, 0) }, /* IBM-specific AR5212 (all others) */ - { PCI_VDEVICE(ATHEROS, PCI_DEVICE_ID_ATHEROS_AR5212_IBM), ATH_LED(0, 0) }, + { PCI_VDEVICE(ATHEROS, PCI_DEVICE_ID_ATHEROS_AR5212_IBM), + .driver_data = ATH_LED(0, 0) }, { } }; -- 1.6.3 -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html