diff options
Diffstat (limited to 'drivers/net/tulip')
-rw-r--r-- | drivers/net/tulip/de2104x.c | 9 | ||||
-rw-r--r-- | drivers/net/tulip/tulip_core.c | 6 | ||||
-rw-r--r-- | drivers/net/tulip/winbond-840.c | 26 |
3 files changed, 15 insertions, 26 deletions
diff --git a/drivers/net/tulip/de2104x.c b/drivers/net/tulip/de2104x.c index 5f743b972949..fc2468ecce0b 100644 --- a/drivers/net/tulip/de2104x.c +++ b/drivers/net/tulip/de2104x.c | |||
@@ -2007,8 +2007,8 @@ static int __init de_init_one (struct pci_dev *pdev, | |||
2007 | } | 2007 | } |
2008 | if (pci_resource_len(pdev, 1) < DE_REGS_SIZE) { | 2008 | if (pci_resource_len(pdev, 1) < DE_REGS_SIZE) { |
2009 | rc = -EIO; | 2009 | rc = -EIO; |
2010 | printk(KERN_ERR PFX "MMIO resource (%lx) too small on pci dev %s\n", | 2010 | printk(KERN_ERR PFX "MMIO resource (%llx) too small on pci dev %s\n", |
2011 | pci_resource_len(pdev, 1), pci_name(pdev)); | 2011 | (unsigned long long)pci_resource_len(pdev, 1), pci_name(pdev)); |
2012 | goto err_out_res; | 2012 | goto err_out_res; |
2013 | } | 2013 | } |
2014 | 2014 | ||
@@ -2016,8 +2016,9 @@ static int __init de_init_one (struct pci_dev *pdev, | |||
2016 | regs = ioremap_nocache(pciaddr, DE_REGS_SIZE); | 2016 | regs = ioremap_nocache(pciaddr, DE_REGS_SIZE); |
2017 | if (!regs) { | 2017 | if (!regs) { |
2018 | rc = -EIO; | 2018 | rc = -EIO; |
2019 | printk(KERN_ERR PFX "Cannot map PCI MMIO (%lx@%lx) on pci dev %s\n", | 2019 | printk(KERN_ERR PFX "Cannot map PCI MMIO (%llx@%lx) on pci dev %s\n", |
2020 | pci_resource_len(pdev, 1), pciaddr, pci_name(pdev)); | 2020 | (unsigned long long)pci_resource_len(pdev, 1), |
2021 | pciaddr, pci_name(pdev)); | ||
2021 | goto err_out_res; | 2022 | goto err_out_res; |
2022 | } | 2023 | } |
2023 | dev->base_addr = (unsigned long) regs; | 2024 | dev->base_addr = (unsigned long) regs; |
diff --git a/drivers/net/tulip/tulip_core.c b/drivers/net/tulip/tulip_core.c index e0de66739a42..53fd9b56d0bd 100644 --- a/drivers/net/tulip/tulip_core.c +++ b/drivers/net/tulip/tulip_core.c | |||
@@ -1350,10 +1350,10 @@ static int __devinit tulip_init_one (struct pci_dev *pdev, | |||
1350 | SET_MODULE_OWNER(dev); | 1350 | SET_MODULE_OWNER(dev); |
1351 | SET_NETDEV_DEV(dev, &pdev->dev); | 1351 | SET_NETDEV_DEV(dev, &pdev->dev); |
1352 | if (pci_resource_len (pdev, 0) < tulip_tbl[chip_idx].io_size) { | 1352 | if (pci_resource_len (pdev, 0) < tulip_tbl[chip_idx].io_size) { |
1353 | printk (KERN_ERR PFX "%s: I/O region (0x%lx@0x%lx) too small, " | 1353 | printk (KERN_ERR PFX "%s: I/O region (0x%llx@0x%llx) too small, " |
1354 | "aborting\n", pci_name(pdev), | 1354 | "aborting\n", pci_name(pdev), |
1355 | pci_resource_len (pdev, 0), | 1355 | (unsigned long long)pci_resource_len (pdev, 0), |
1356 | pci_resource_start (pdev, 0)); | 1356 | (unsigned long long)pci_resource_start (pdev, 0)); |
1357 | goto err_out_free_netdev; | 1357 | goto err_out_free_netdev; |
1358 | } | 1358 | } |
1359 | 1359 | ||
diff --git a/drivers/net/tulip/winbond-840.c b/drivers/net/tulip/winbond-840.c index 8fea2aa455d4..602a6e5002a0 100644 --- a/drivers/net/tulip/winbond-840.c +++ b/drivers/net/tulip/winbond-840.c | |||
@@ -212,26 +212,15 @@ Test with 'ping -s 10000' on a fast computer. | |||
212 | /* | 212 | /* |
213 | PCI probe table. | 213 | PCI probe table. |
214 | */ | 214 | */ |
215 | enum pci_id_flags_bits { | ||
216 | /* Set PCI command register bits before calling probe1(). */ | ||
217 | PCI_USES_IO=1, PCI_USES_MEM=2, PCI_USES_MASTER=4, | ||
218 | /* Read and map the single following PCI BAR. */ | ||
219 | PCI_ADDR0=0<<4, PCI_ADDR1=1<<4, PCI_ADDR2=2<<4, PCI_ADDR3=3<<4, | ||
220 | PCI_ADDR_64BITS=0x100, PCI_NO_ACPI_WAKE=0x200, PCI_NO_MIN_LATENCY=0x400, | ||
221 | }; | ||
222 | enum chip_capability_flags { | 215 | enum chip_capability_flags { |
223 | CanHaveMII=1, HasBrokenTx=2, AlwaysFDX=4, FDXOnNoMII=8,}; | 216 | CanHaveMII=1, HasBrokenTx=2, AlwaysFDX=4, FDXOnNoMII=8, |
224 | #ifdef USE_IO_OPS | 217 | }; |
225 | #define W840_FLAGS (PCI_USES_IO | PCI_ADDR0 | PCI_USES_MASTER) | ||
226 | #else | ||
227 | #define W840_FLAGS (PCI_USES_MEM | PCI_ADDR1 | PCI_USES_MASTER) | ||
228 | #endif | ||
229 | 218 | ||
230 | static struct pci_device_id w840_pci_tbl[] = { | 219 | static const struct pci_device_id w840_pci_tbl[] = { |
231 | { 0x1050, 0x0840, PCI_ANY_ID, 0x8153, 0, 0, 0 }, | 220 | { 0x1050, 0x0840, PCI_ANY_ID, 0x8153, 0, 0, 0 }, |
232 | { 0x1050, 0x0840, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 1 }, | 221 | { 0x1050, 0x0840, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 1 }, |
233 | { 0x11f6, 0x2011, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 2 }, | 222 | { 0x11f6, 0x2011, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 2 }, |
234 | { 0, } | 223 | { } |
235 | }; | 224 | }; |
236 | MODULE_DEVICE_TABLE(pci, w840_pci_tbl); | 225 | MODULE_DEVICE_TABLE(pci, w840_pci_tbl); |
237 | 226 | ||
@@ -241,18 +230,17 @@ struct pci_id_info { | |||
241 | int pci, pci_mask, subsystem, subsystem_mask; | 230 | int pci, pci_mask, subsystem, subsystem_mask; |
242 | int revision, revision_mask; /* Only 8 bits. */ | 231 | int revision, revision_mask; /* Only 8 bits. */ |
243 | } id; | 232 | } id; |
244 | enum pci_id_flags_bits pci_flags; | ||
245 | int io_size; /* Needed for I/O region check or ioremap(). */ | 233 | int io_size; /* Needed for I/O region check or ioremap(). */ |
246 | int drv_flags; /* Driver use, intended as capability flags. */ | 234 | int drv_flags; /* Driver use, intended as capability flags. */ |
247 | }; | 235 | }; |
248 | static struct pci_id_info pci_id_tbl[] = { | 236 | static struct pci_id_info pci_id_tbl[] = { |
249 | {"Winbond W89c840", /* Sometime a Level-One switch card. */ | 237 | {"Winbond W89c840", /* Sometime a Level-One switch card. */ |
250 | { 0x08401050, 0xffffffff, 0x81530000, 0xffff0000 }, | 238 | { 0x08401050, 0xffffffff, 0x81530000, 0xffff0000 }, |
251 | W840_FLAGS, 128, CanHaveMII | HasBrokenTx | FDXOnNoMII}, | 239 | 128, CanHaveMII | HasBrokenTx | FDXOnNoMII}, |
252 | {"Winbond W89c840", { 0x08401050, 0xffffffff, }, | 240 | {"Winbond W89c840", { 0x08401050, 0xffffffff, }, |
253 | W840_FLAGS, 128, CanHaveMII | HasBrokenTx}, | 241 | 128, CanHaveMII | HasBrokenTx}, |
254 | {"Compex RL100-ATX", { 0x201111F6, 0xffffffff,}, | 242 | {"Compex RL100-ATX", { 0x201111F6, 0xffffffff,}, |
255 | W840_FLAGS, 128, CanHaveMII | HasBrokenTx}, | 243 | 128, CanHaveMII | HasBrokenTx}, |
256 | {NULL,}, /* 0 terminated list. */ | 244 | {NULL,}, /* 0 terminated list. */ |
257 | }; | 245 | }; |
258 | 246 | ||