ath9k: use pci_dev->subsystem_device
Subsystems (3)
PATCH 1/1 ath9k: use pci_dev->subsystem_device
The driver reads PCI subsystem ID from the PCI configuration register while it's already stored by the PCI subsystem in the 'subsystem_device' field of 'struct pci_dev'...
Signed-off-by Sergei Shtylyov <[email protected]>
---
The patch is against the recent Linus' tree.
drivers/net/wireless/ath/ath9k/pci.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/net/wireless/ath/ath9k/pci.c +2 -3
@@ -129,7 +129,6 @@ static int ath_pci_probe(struct pci_devstruct ath_softc *sc;struct ieee80211_hw *hw;u8 csz; -u16 subsysid;u32 val;int ret =0 ;char hw_name[64 ];
@@ -223,8 +222,8 @@ static int ath_pci_probe(struct pci_dev sc->irq = pdev->irq; -pci_read_config_word (pdev,PCI_SUBSYSTEM_ID , &subsysid); - ret =ath9k_init_device (id->device, sc, subsysid, &ath_pci_bus_ops); + ret =ath9k_init_device (id->device, sc, pdev->subsystem_device, + &ath_pci_bus_ops);if (ret) {dev_err (&pdev->dev,"Failed to initialize device\n" ); goto err_init;
A message that is not in the archive (sent off-list or not yet received): 201107221958.23408.sshtylyov-hkdhdckH98+B+jHODAdFcQ@public.gmane.org
Quoted 5 lines · Sergei Shtylyov
The driver reads PCI subsystem ID from the PCI configuration register while it's already stored by the PCI subsystem in the '
subsystem_device' field of 'structpci_dev'...Signed-off-by Sergei Shtylyov<[email protected]>
subsysid doesn't appear to be used anywhere. It can be removed easily.
The patch will be sent separately.
Signature · 2 lines
Regards, Pavel Roskin