diff options
Diffstat (limited to 'drivers/net/ethernet/via/via-velocity.c')
-rw-r--r-- | drivers/net/ethernet/via/via-velocity.c | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/drivers/net/ethernet/via/via-velocity.c b/drivers/net/ethernet/via/via-velocity.c index a46c19859683..dc9edd48c933 100644 --- a/drivers/net/ethernet/via/via-velocity.c +++ b/drivers/net/ethernet/via/via-velocity.c | |||
@@ -375,7 +375,7 @@ MODULE_DEVICE_TABLE(pci, velocity_id_table); | |||
375 | * Given a chip identifier return a suitable description. Returns | 375 | * Given a chip identifier return a suitable description. Returns |
376 | * a pointer a static string valid while the driver is loaded. | 376 | * a pointer a static string valid while the driver is loaded. |
377 | */ | 377 | */ |
378 | static const char __devinit *get_chip_name(enum chip_type chip_id) | 378 | static const char *get_chip_name(enum chip_type chip_id) |
379 | { | 379 | { |
380 | int i; | 380 | int i; |
381 | for (i = 0; chip_info_table[i].name != NULL; i++) | 381 | for (i = 0; chip_info_table[i].name != NULL; i++) |
@@ -392,7 +392,7 @@ static const char __devinit *get_chip_name(enum chip_type chip_id) | |||
392 | * unload for each active device that is present. Disconnects | 392 | * unload for each active device that is present. Disconnects |
393 | * the device from the network layer and frees all the resources | 393 | * the device from the network layer and frees all the resources |
394 | */ | 394 | */ |
395 | static void __devexit velocity_remove1(struct pci_dev *pdev) | 395 | static void velocity_remove1(struct pci_dev *pdev) |
396 | { | 396 | { |
397 | struct net_device *dev = pci_get_drvdata(pdev); | 397 | struct net_device *dev = pci_get_drvdata(pdev); |
398 | struct velocity_info *vptr = netdev_priv(dev); | 398 | struct velocity_info *vptr = netdev_priv(dev); |
@@ -421,7 +421,8 @@ static void __devexit velocity_remove1(struct pci_dev *pdev) | |||
421 | * all the verification and checking as well as reporting so that | 421 | * all the verification and checking as well as reporting so that |
422 | * we don't duplicate code for each option. | 422 | * we don't duplicate code for each option. |
423 | */ | 423 | */ |
424 | static void __devinit velocity_set_int_opt(int *opt, int val, int min, int max, int def, char *name, const char *devname) | 424 | static void velocity_set_int_opt(int *opt, int val, int min, int max, int def, |
425 | char *name, const char *devname) | ||
425 | { | 426 | { |
426 | if (val == -1) | 427 | if (val == -1) |
427 | *opt = def; | 428 | *opt = def; |
@@ -449,7 +450,8 @@ static void __devinit velocity_set_int_opt(int *opt, int val, int min, int max, | |||
449 | * all the verification and checking as well as reporting so that | 450 | * all the verification and checking as well as reporting so that |
450 | * we don't duplicate code for each option. | 451 | * we don't duplicate code for each option. |
451 | */ | 452 | */ |
452 | static void __devinit velocity_set_bool_opt(u32 *opt, int val, int def, u32 flag, char *name, const char *devname) | 453 | static void velocity_set_bool_opt(u32 *opt, int val, int def, u32 flag, |
454 | char *name, const char *devname) | ||
453 | { | 455 | { |
454 | (*opt) &= (~flag); | 456 | (*opt) &= (~flag); |
455 | if (val == -1) | 457 | if (val == -1) |
@@ -474,7 +476,8 @@ static void __devinit velocity_set_bool_opt(u32 *opt, int val, int def, u32 flag | |||
474 | * Turn the module and command options into a single structure | 476 | * Turn the module and command options into a single structure |
475 | * for the current device | 477 | * for the current device |
476 | */ | 478 | */ |
477 | static void __devinit velocity_get_options(struct velocity_opt *opts, int index, const char *devname) | 479 | static void velocity_get_options(struct velocity_opt *opts, int index, |
480 | const char *devname) | ||
478 | { | 481 | { |
479 | 482 | ||
480 | velocity_set_int_opt(&opts->rx_thresh, rx_thresh[index], RX_THRESH_MIN, RX_THRESH_MAX, RX_THRESH_DEF, "rx_thresh", devname); | 483 | velocity_set_int_opt(&opts->rx_thresh, rx_thresh[index], RX_THRESH_MIN, RX_THRESH_MAX, RX_THRESH_DEF, "rx_thresh", devname); |
@@ -2627,7 +2630,7 @@ static const struct net_device_ops velocity_netdev_ops = { | |||
2627 | * Set up the initial velocity_info struct for the device that has been | 2630 | * Set up the initial velocity_info struct for the device that has been |
2628 | * discovered. | 2631 | * discovered. |
2629 | */ | 2632 | */ |
2630 | static void __devinit velocity_init_info(struct pci_dev *pdev, | 2633 | static void velocity_init_info(struct pci_dev *pdev, |
2631 | struct velocity_info *vptr, | 2634 | struct velocity_info *vptr, |
2632 | const struct velocity_info_tbl *info) | 2635 | const struct velocity_info_tbl *info) |
2633 | { | 2636 | { |
@@ -2648,7 +2651,8 @@ static void __devinit velocity_init_info(struct pci_dev *pdev, | |||
2648 | * Retrieve the PCI configuration space data that interests us from | 2651 | * Retrieve the PCI configuration space data that interests us from |
2649 | * the kernel PCI layer | 2652 | * the kernel PCI layer |
2650 | */ | 2653 | */ |
2651 | static int __devinit velocity_get_pci_info(struct velocity_info *vptr, struct pci_dev *pdev) | 2654 | static int velocity_get_pci_info(struct velocity_info *vptr, |
2655 | struct pci_dev *pdev) | ||
2652 | { | 2656 | { |
2653 | vptr->rev_id = pdev->revision; | 2657 | vptr->rev_id = pdev->revision; |
2654 | 2658 | ||
@@ -2685,7 +2689,7 @@ static int __devinit velocity_get_pci_info(struct velocity_info *vptr, struct pc | |||
2685 | * Print per driver data as the kernel driver finds Velocity | 2689 | * Print per driver data as the kernel driver finds Velocity |
2686 | * hardware | 2690 | * hardware |
2687 | */ | 2691 | */ |
2688 | static void __devinit velocity_print_info(struct velocity_info *vptr) | 2692 | static void velocity_print_info(struct velocity_info *vptr) |
2689 | { | 2693 | { |
2690 | struct net_device *dev = vptr->dev; | 2694 | struct net_device *dev = vptr->dev; |
2691 | 2695 | ||
@@ -2709,7 +2713,8 @@ static u32 velocity_get_link(struct net_device *dev) | |||
2709 | * Configure a discovered adapter from scratch. Return a negative | 2713 | * Configure a discovered adapter from scratch. Return a negative |
2710 | * errno error code on failure paths. | 2714 | * errno error code on failure paths. |
2711 | */ | 2715 | */ |
2712 | static int __devinit velocity_found1(struct pci_dev *pdev, const struct pci_device_id *ent) | 2716 | static int velocity_found1(struct pci_dev *pdev, |
2717 | const struct pci_device_id *ent) | ||
2713 | { | 2718 | { |
2714 | static int first = 1; | 2719 | static int first = 1; |
2715 | struct net_device *dev; | 2720 | struct net_device *dev; |
@@ -3108,7 +3113,7 @@ static struct pci_driver velocity_driver = { | |||
3108 | .name = VELOCITY_NAME, | 3113 | .name = VELOCITY_NAME, |
3109 | .id_table = velocity_id_table, | 3114 | .id_table = velocity_id_table, |
3110 | .probe = velocity_found1, | 3115 | .probe = velocity_found1, |
3111 | .remove = __devexit_p(velocity_remove1), | 3116 | .remove = velocity_remove1, |
3112 | #ifdef CONFIG_PM | 3117 | #ifdef CONFIG_PM |
3113 | .suspend = velocity_suspend, | 3118 | .suspend = velocity_suspend, |
3114 | .resume = velocity_resume, | 3119 | .resume = velocity_resume, |