Use compatibility definition for IRQF_SHARED
[madwifi/.git] / ath / if_ath_pci.c
index 828122bd3f322014cf385ce88dfc848f2007a2a8..9ad9667d683d022c524cb01825169716e4412e32 100644 (file)
@@ -155,7 +155,7 @@ ath_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
         * set it to the value used by other systems.  It may be worth
         * tweaking this setting more.
         */
-       pci_write_config_byte(pdev, PCI_LATENCY_TIMER, 0xa8);
+       pci_write_config_byte(pdev, PCI_LATENCY_TIMER, 0x60);
 
        pci_set_master(pdev);
 
@@ -197,10 +197,6 @@ ath_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
        sc->aps_sc.sc_invalid = 1;
 
        dev->irq = pdev->irq;
-       /*
-        * Don't leave arp type as ARPHRD_ETHER as this is no eth device
-        */
-       dev->type = ARPHRD_IEEE80211;
 
        SET_MODULE_OWNER(dev);
        SET_NETDEV_DEV(dev, &pdev->dev);
@@ -209,19 +205,14 @@ ath_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 
        pci_set_drvdata(pdev, dev);
 
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,22)
        if (request_irq(dev->irq, ath_intr, IRQF_SHARED, dev->name, dev)) {
-#else
-       if (request_irq(dev->irq, ath_intr, SA_SHIRQ, dev->name, dev)) {
-#endif
-
                printk(KERN_WARNING "%s: request_irq failed\n", dev->name);
                goto bad3;
        }
 
        /* looking for device type from broken device id */
        vdevice = id->device;
-       for (i = 0; i < (sizeof(ath_devidmap) / sizeof(ath_devidmap[0])); i++) {
+       for (i = 0; i < ARRAY_SIZE(ath_devidmap); i++) {
                if (id->device == ath_devidmap[i][0]) {
                        vdevice = ath_devidmap[i][1];
                        break;
@@ -347,9 +338,8 @@ static struct pci_driver ath_pci_drv_id = {
 /*
  * Module glue.
  */
-#include "version.h"
 #include "release.h"
-static char *version = ATH_PCI_VERSION " (" RELEASE_VERSION ")";
+static char *version = RELEASE_VERSION;
 static char *dev_info = "ath_pci";
 
 #include <linux/ethtool.h>