rt2x00: Allow dynamic addition of PCI/USB IDs.
Both USB and PCI drivers allow a system administrator to dynamically add USB/PCI IDs to the device table that a driver supports via the /sys/bus/{usb,pci,pci_express}/drivers/<driver-name>/new_id files. However, for the rt2x00 drivers using this method currently crashes the system with a NULL pointer failure. This is due to the set-up of rt2x00 where the probe functions require a rt2x00_ops structure in the driver_info field of the probed device. As this field is empty for the dynamically added devices this fails for these devices. Fix this by introducing driver-specific probe wrappers that do nothing but calling the bus-specific probe functions with the rt2x00_ops structure as an argument, rather than depending on the driver_info field. Signed-off-by:Gertjan van Wingerde <gwingerde@gmail.com> Signed-off-by:
Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by:
John W. Linville <linville@tuxdriver.com>
Showing
- drivers/net/wireless/rt2x00/rt2400pci.c 9 additions, 2 deletionsdrivers/net/wireless/rt2x00/rt2400pci.c
- drivers/net/wireless/rt2x00/rt2500pci.c 8 additions, 2 deletionsdrivers/net/wireless/rt2x00/rt2500pci.c
- drivers/net/wireless/rt2x00/rt2500usb.c 38 additions, 32 deletionsdrivers/net/wireless/rt2x00/rt2500usb.c
- drivers/net/wireless/rt2x00/rt2800pci.c 32 additions, 26 deletionsdrivers/net/wireless/rt2x00/rt2800pci.c
- drivers/net/wireless/rt2x00/rt2800usb.c 223 additions, 217 deletionsdrivers/net/wireless/rt2x00/rt2800usb.c
- drivers/net/wireless/rt2x00/rt2x00pci.c 1 addition, 2 deletionsdrivers/net/wireless/rt2x00/rt2x00pci.c
- drivers/net/wireless/rt2x00/rt2x00pci.h 1 addition, 1 deletiondrivers/net/wireless/rt2x00/rt2x00pci.h
- drivers/net/wireless/rt2x00/rt2x00usb.c 1 addition, 2 deletionsdrivers/net/wireless/rt2x00/rt2x00usb.c
- drivers/net/wireless/rt2x00/rt2x00usb.h 1 addition, 7 deletionsdrivers/net/wireless/rt2x00/rt2x00usb.h
- drivers/net/wireless/rt2x00/rt61pci.c 10 additions, 4 deletionsdrivers/net/wireless/rt2x00/rt61pci.c
- drivers/net/wireless/rt2x00/rt73usb.c 80 additions, 74 deletionsdrivers/net/wireless/rt2x00/rt73usb.c
Loading
Please register or sign in to comment