aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/fealnx.c
diff options
context:
space:
mode:
authorJeff Garzik <jeff@garzik.org>2006-06-27 09:12:38 -0400
committerJeff Garzik <jeff@garzik.org>2006-07-05 13:40:50 -0400
commit46009c8bcd5d7c9fcbfc17d0455a471bea5be4d4 (patch)
treec9ab3cd5bf6ed74bf91a9644b566fc4ea7ff710e /drivers/net/fealnx.c
parent8ab6f3f706f5cb91bc0793afc95c8809837ece05 (diff)
[netdrvr] minor cleanups in Becker-derived drivers
- fealnx: convert #define to enum - fealnx, sundance: mark chip info table __devinitdata - fealnx: use dev_printk() during probe - fealnx: formatting cleanups - starfire: remove obsolete comment - sundance, via-rhine: add some whitespace where useful, in tables - sundance: prefer "{ }" table terminator - via-rhine: mark PCI probe table const Signed-off-by: Jeff Garzik <jeff@garzik.org>
Diffstat (limited to 'drivers/net/fealnx.c')
-rw-r--r--drivers/net/fealnx.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/net/fealnx.c b/drivers/net/fealnx.c
index 0e6a495549fa..aaf136658765 100644
--- a/drivers/net/fealnx.c
+++ b/drivers/net/fealnx.c
@@ -124,7 +124,9 @@ MODULE_PARM_DESC(multicast_filter_limit, "fealnx maximum number of filtered mult
124MODULE_PARM_DESC(options, "fealnx: Bits 0-3: media type, bit 17: full duplex"); 124MODULE_PARM_DESC(options, "fealnx: Bits 0-3: media type, bit 17: full duplex");
125MODULE_PARM_DESC(full_duplex, "fealnx full duplex setting(s) (1)"); 125MODULE_PARM_DESC(full_duplex, "fealnx full duplex setting(s) (1)");
126 126
127#define MIN_REGION_SIZE 136 127enum {
128 MIN_REGION_SIZE = 136,
129};
128 130
129/* A chip capabilities table, matching the entries in pci_tbl[] above. */ 131/* A chip capabilities table, matching the entries in pci_tbl[] above. */
130enum chip_capability_flags { 132enum chip_capability_flags {
@@ -149,7 +151,7 @@ struct chip_info {
149 int flags; 151 int flags;
150}; 152};
151 153
152static const struct chip_info skel_netdrv_tbl[] = { 154static const struct chip_info skel_netdrv_tbl[] __devinitdata = {
153 { "100/10M Ethernet PCI Adapter", HAS_MII_XCVR }, 155 { "100/10M Ethernet PCI Adapter", HAS_MII_XCVR },
154 { "100/10M Ethernet PCI Adapter", HAS_CHIP_XCVR }, 156 { "100/10M Ethernet PCI Adapter", HAS_CHIP_XCVR },
155 { "1000/100/10M Ethernet PCI Adapter", HAS_MII_XCVR }, 157 { "1000/100/10M Ethernet PCI Adapter", HAS_MII_XCVR },
@@ -503,13 +505,14 @@ static int __devinit fealnx_init_one(struct pci_dev *pdev,
503 505
504 len = pci_resource_len(pdev, bar); 506 len = pci_resource_len(pdev, bar);
505 if (len < MIN_REGION_SIZE) { 507 if (len < MIN_REGION_SIZE) {
506 printk(KERN_ERR "%s: region size %ld too small, aborting\n", 508 dev_printk(KERN_ERR, &pdev->dev,
507 boardname, len); 509 "region size %ld too small, aborting\n", len);
508 return -ENODEV; 510 return -ENODEV;
509 } 511 }
510 512
511 i = pci_request_regions(pdev, boardname); 513 i = pci_request_regions(pdev, boardname);
512 if (i) return i; 514 if (i)
515 return i;
513 516
514 irq = pdev->irq; 517 irq = pdev->irq;
515 518