diff options
author | Mark Rusk <Mark.Rusk@hp.com> | 2012-11-06 20:33:13 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-11-16 01:35:59 (GMT) |
commit | ebf1b764aa5cb3b4bfe2e96674f1b559f7c37e64 (patch) | |
tree | aa9c9b21247d60bab3c773f04ad95a52ad057c50 /drivers | |
parent | 04bfd1dfb2c0ef236553d205bd95be02792c3396 (diff) | |
download | linux-ebf1b764aa5cb3b4bfe2e96674f1b559f7c37e64.tar.xz |
misc: hpilo: ignore auxiliary HP iLO BMC's
This patch ignores auxiliary HP Lights-Out (iLO) management controllers.
All HP iLO controllers that have had the PCI subsystem device ID set to 0x1979
by the BIOS are ignored. Also changes default number of channels to 16 and
bumps the version of the module from 1.3 to 1.4.
Signed-off-by: Mark Rusk <mark.rusk@hp.com>
----
drivers/misc/hpilo.c | 15 +++++++++++----
1 files changed, 11 insertions(+), 4 deletions(-)
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/misc/hpilo.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/drivers/misc/hpilo.c b/drivers/misc/hpilo.c index 12ccdf9..b362d93 100644 --- a/drivers/misc/hpilo.c +++ b/drivers/misc/hpilo.c @@ -30,7 +30,7 @@ static struct class *ilo_class; static unsigned int ilo_major; -static unsigned int max_ccb = MIN_CCB; +static unsigned int max_ccb = 16; static char ilo_hwdev[MAX_ILO_DEV]; static inline int get_entry_id(int entry) @@ -725,6 +725,9 @@ static void ilo_remove(struct pci_dev *pdev) int i, minor; struct ilo_hwinfo *ilo_hw = pci_get_drvdata(pdev); + if (!ilo_hw) + return; + clear_device(ilo_hw); minor = MINOR(ilo_hw->cdev.dev); @@ -751,9 +754,13 @@ static void ilo_remove(struct pci_dev *pdev) static int __devinit ilo_probe(struct pci_dev *pdev, const struct pci_device_id *ent) { - int devnum, minor, start, error; + int devnum, minor, start, error = 0; struct ilo_hwinfo *ilo_hw; + /* Ignore subsystem_device = 0x1979 (set by BIOS) */ + if (pdev->subsystem_device == 0x1979) + goto out; + if (max_ccb > MAX_CCB) max_ccb = MAX_CCB; else if (max_ccb < MIN_CCB) @@ -892,14 +899,14 @@ static void __exit ilo_exit(void) class_destroy(ilo_class); } -MODULE_VERSION("1.3"); +MODULE_VERSION("1.4"); MODULE_ALIAS(ILO_NAME); MODULE_DESCRIPTION(ILO_NAME); MODULE_AUTHOR("David Altobelli <david.altobelli@hp.com>"); MODULE_LICENSE("GPL v2"); module_param(max_ccb, uint, 0444); -MODULE_PARM_DESC(max_ccb, "Maximum number of HP iLO channels to attach (8)"); +MODULE_PARM_DESC(max_ccb, "Maximum number of HP iLO channels to attach (16)"); module_init(ilo_init); module_exit(ilo_exit); |