aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/misc/hpilo.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/drivers/misc/hpilo.c b/drivers/misc/hpilo.c
index 12ccdf94e4fa..b362d938e929 100644
--- a/drivers/misc/hpilo.c
+++ b/drivers/misc/hpilo.c
@@ -30,7 +30,7 @@
30 30
31static struct class *ilo_class; 31static struct class *ilo_class;
32static unsigned int ilo_major; 32static unsigned int ilo_major;
33static unsigned int max_ccb = MIN_CCB; 33static unsigned int max_ccb = 16;
34static char ilo_hwdev[MAX_ILO_DEV]; 34static char ilo_hwdev[MAX_ILO_DEV];
35 35
36static inline int get_entry_id(int entry) 36static inline int get_entry_id(int entry)
@@ -725,6 +725,9 @@ static void ilo_remove(struct pci_dev *pdev)
725 int i, minor; 725 int i, minor;
726 struct ilo_hwinfo *ilo_hw = pci_get_drvdata(pdev); 726 struct ilo_hwinfo *ilo_hw = pci_get_drvdata(pdev);
727 727
728 if (!ilo_hw)
729 return;
730
728 clear_device(ilo_hw); 731 clear_device(ilo_hw);
729 732
730 minor = MINOR(ilo_hw->cdev.dev); 733 minor = MINOR(ilo_hw->cdev.dev);
@@ -751,9 +754,13 @@ static void ilo_remove(struct pci_dev *pdev)
751static int __devinit ilo_probe(struct pci_dev *pdev, 754static int __devinit ilo_probe(struct pci_dev *pdev,
752 const struct pci_device_id *ent) 755 const struct pci_device_id *ent)
753{ 756{
754 int devnum, minor, start, error; 757 int devnum, minor, start, error = 0;
755 struct ilo_hwinfo *ilo_hw; 758 struct ilo_hwinfo *ilo_hw;
756 759
760 /* Ignore subsystem_device = 0x1979 (set by BIOS) */
761 if (pdev->subsystem_device == 0x1979)
762 goto out;
763
757 if (max_ccb > MAX_CCB) 764 if (max_ccb > MAX_CCB)
758 max_ccb = MAX_CCB; 765 max_ccb = MAX_CCB;
759 else if (max_ccb < MIN_CCB) 766 else if (max_ccb < MIN_CCB)
@@ -892,14 +899,14 @@ static void __exit ilo_exit(void)
892 class_destroy(ilo_class); 899 class_destroy(ilo_class);
893} 900}
894 901
895MODULE_VERSION("1.3"); 902MODULE_VERSION("1.4");
896MODULE_ALIAS(ILO_NAME); 903MODULE_ALIAS(ILO_NAME);
897MODULE_DESCRIPTION(ILO_NAME); 904MODULE_DESCRIPTION(ILO_NAME);
898MODULE_AUTHOR("David Altobelli <david.altobelli@hp.com>"); 905MODULE_AUTHOR("David Altobelli <david.altobelli@hp.com>");
899MODULE_LICENSE("GPL v2"); 906MODULE_LICENSE("GPL v2");
900 907
901module_param(max_ccb, uint, 0444); 908module_param(max_ccb, uint, 0444);
902MODULE_PARM_DESC(max_ccb, "Maximum number of HP iLO channels to attach (8)"); 909MODULE_PARM_DESC(max_ccb, "Maximum number of HP iLO channels to attach (16)");
903 910
904module_init(ilo_init); 911module_init(ilo_init);
905module_exit(ilo_exit); 912module_exit(ilo_exit);