diff options
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2400pci.c')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2400pci.c | 29 |
1 files changed, 20 insertions, 9 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2400pci.c b/drivers/net/wireless/rt2x00/rt2400pci.c index 137a24e520da..937f9e8bf05f 100644 --- a/drivers/net/wireless/rt2x00/rt2400pci.c +++ b/drivers/net/wireless/rt2x00/rt2400pci.c | |||
@@ -1314,8 +1314,8 @@ static void rt2400pci_txdone(struct rt2x00_dev *rt2x00dev, | |||
1314 | } | 1314 | } |
1315 | } | 1315 | } |
1316 | 1316 | ||
1317 | static void rt2400pci_enable_interrupt(struct rt2x00_dev *rt2x00dev, | 1317 | static inline void rt2400pci_enable_interrupt(struct rt2x00_dev *rt2x00dev, |
1318 | struct rt2x00_field32 irq_field) | 1318 | struct rt2x00_field32 irq_field) |
1319 | { | 1319 | { |
1320 | u32 reg; | 1320 | u32 reg; |
1321 | 1321 | ||
@@ -1536,13 +1536,13 @@ static int rt2400pci_init_eeprom(struct rt2x00_dev *rt2x00dev) | |||
1536 | * Detect if this device has an hardware controlled radio. | 1536 | * Detect if this device has an hardware controlled radio. |
1537 | */ | 1537 | */ |
1538 | if (rt2x00_get_field16(eeprom, EEPROM_ANTENNA_HARDWARE_RADIO)) | 1538 | if (rt2x00_get_field16(eeprom, EEPROM_ANTENNA_HARDWARE_RADIO)) |
1539 | __set_bit(CONFIG_SUPPORT_HW_BUTTON, &rt2x00dev->flags); | 1539 | __set_bit(CAPABILITY_HW_BUTTON, &rt2x00dev->cap_flags); |
1540 | 1540 | ||
1541 | /* | 1541 | /* |
1542 | * Check if the BBP tuning should be enabled. | 1542 | * Check if the BBP tuning should be enabled. |
1543 | */ | 1543 | */ |
1544 | if (rt2x00_get_field16(eeprom, EEPROM_ANTENNA_RX_AGCVGC_TUNING)) | 1544 | if (rt2x00_get_field16(eeprom, EEPROM_ANTENNA_RX_AGCVGC_TUNING)) |
1545 | __set_bit(DRIVER_SUPPORT_LINK_TUNING, &rt2x00dev->flags); | 1545 | __set_bit(CAPABILITY_LINK_TUNING, &rt2x00dev->cap_flags); |
1546 | 1546 | ||
1547 | return 0; | 1547 | return 0; |
1548 | } | 1548 | } |
@@ -1640,9 +1640,9 @@ static int rt2400pci_probe_hw(struct rt2x00_dev *rt2x00dev) | |||
1640 | /* | 1640 | /* |
1641 | * This device requires the atim queue and DMA-mapped skbs. | 1641 | * This device requires the atim queue and DMA-mapped skbs. |
1642 | */ | 1642 | */ |
1643 | __set_bit(DRIVER_REQUIRE_ATIM_QUEUE, &rt2x00dev->flags); | 1643 | __set_bit(REQUIRE_ATIM_QUEUE, &rt2x00dev->cap_flags); |
1644 | __set_bit(DRIVER_REQUIRE_DMA, &rt2x00dev->flags); | 1644 | __set_bit(REQUIRE_DMA, &rt2x00dev->cap_flags); |
1645 | __set_bit(DRIVER_REQUIRE_SW_SEQNO, &rt2x00dev->flags); | 1645 | __set_bit(REQUIRE_SW_SEQNO, &rt2x00dev->cap_flags); |
1646 | 1646 | ||
1647 | /* | 1647 | /* |
1648 | * Set the rssi offset. | 1648 | * Set the rssi offset. |
@@ -1720,6 +1720,9 @@ static const struct ieee80211_ops rt2400pci_mac80211_ops = { | |||
1720 | .tx_last_beacon = rt2400pci_tx_last_beacon, | 1720 | .tx_last_beacon = rt2400pci_tx_last_beacon, |
1721 | .rfkill_poll = rt2x00mac_rfkill_poll, | 1721 | .rfkill_poll = rt2x00mac_rfkill_poll, |
1722 | .flush = rt2x00mac_flush, | 1722 | .flush = rt2x00mac_flush, |
1723 | .set_antenna = rt2x00mac_set_antenna, | ||
1724 | .get_antenna = rt2x00mac_get_antenna, | ||
1725 | .get_ringparam = rt2x00mac_get_ringparam, | ||
1723 | }; | 1726 | }; |
1724 | 1727 | ||
1725 | static const struct rt2x00lib_ops rt2400pci_rt2x00_ops = { | 1728 | static const struct rt2x00lib_ops rt2400pci_rt2x00_ops = { |
@@ -1740,6 +1743,7 @@ static const struct rt2x00lib_ops rt2400pci_rt2x00_ops = { | |||
1740 | .start_queue = rt2400pci_start_queue, | 1743 | .start_queue = rt2400pci_start_queue, |
1741 | .kick_queue = rt2400pci_kick_queue, | 1744 | .kick_queue = rt2400pci_kick_queue, |
1742 | .stop_queue = rt2400pci_stop_queue, | 1745 | .stop_queue = rt2400pci_stop_queue, |
1746 | .flush_queue = rt2x00pci_flush_queue, | ||
1743 | .write_tx_desc = rt2400pci_write_tx_desc, | 1747 | .write_tx_desc = rt2400pci_write_tx_desc, |
1744 | .write_beacon = rt2400pci_write_beacon, | 1748 | .write_beacon = rt2400pci_write_beacon, |
1745 | .fill_rxdone = rt2400pci_fill_rxdone, | 1749 | .fill_rxdone = rt2400pci_fill_rxdone, |
@@ -1801,10 +1805,11 @@ static const struct rt2x00_ops rt2400pci_ops = { | |||
1801 | * RT2400pci module information. | 1805 | * RT2400pci module information. |
1802 | */ | 1806 | */ |
1803 | static DEFINE_PCI_DEVICE_TABLE(rt2400pci_device_table) = { | 1807 | static DEFINE_PCI_DEVICE_TABLE(rt2400pci_device_table) = { |
1804 | { PCI_DEVICE(0x1814, 0x0101), PCI_DEVICE_DATA(&rt2400pci_ops) }, | 1808 | { PCI_DEVICE(0x1814, 0x0101) }, |
1805 | { 0, } | 1809 | { 0, } |
1806 | }; | 1810 | }; |
1807 | 1811 | ||
1812 | |||
1808 | MODULE_AUTHOR(DRV_PROJECT); | 1813 | MODULE_AUTHOR(DRV_PROJECT); |
1809 | MODULE_VERSION(DRV_VERSION); | 1814 | MODULE_VERSION(DRV_VERSION); |
1810 | MODULE_DESCRIPTION("Ralink RT2400 PCI & PCMCIA Wireless LAN driver."); | 1815 | MODULE_DESCRIPTION("Ralink RT2400 PCI & PCMCIA Wireless LAN driver."); |
@@ -1812,10 +1817,16 @@ MODULE_SUPPORTED_DEVICE("Ralink RT2460 PCI & PCMCIA chipset based cards"); | |||
1812 | MODULE_DEVICE_TABLE(pci, rt2400pci_device_table); | 1817 | MODULE_DEVICE_TABLE(pci, rt2400pci_device_table); |
1813 | MODULE_LICENSE("GPL"); | 1818 | MODULE_LICENSE("GPL"); |
1814 | 1819 | ||
1820 | static int rt2400pci_probe(struct pci_dev *pci_dev, | ||
1821 | const struct pci_device_id *id) | ||
1822 | { | ||
1823 | return rt2x00pci_probe(pci_dev, &rt2400pci_ops); | ||
1824 | } | ||
1825 | |||
1815 | static struct pci_driver rt2400pci_driver = { | 1826 | static struct pci_driver rt2400pci_driver = { |
1816 | .name = KBUILD_MODNAME, | 1827 | .name = KBUILD_MODNAME, |
1817 | .id_table = rt2400pci_device_table, | 1828 | .id_table = rt2400pci_device_table, |
1818 | .probe = rt2x00pci_probe, | 1829 | .probe = rt2400pci_probe, |
1819 | .remove = __devexit_p(rt2x00pci_remove), | 1830 | .remove = __devexit_p(rt2x00pci_remove), |
1820 | .suspend = rt2x00pci_suspend, | 1831 | .suspend = rt2x00pci_suspend, |
1821 | .resume = rt2x00pci_resume, | 1832 | .resume = rt2x00pci_resume, |