aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2008-07-14 10:28:32 -0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2008-07-19 00:50:30 -0400
commit305e342bba16730a0821131af6d7d0df43bfff4c (patch)
tree46417cba885d51088c1068caf4b0347ab8488a12 /drivers/input
parentf3d1eb19abdcb1e740d8ba0e06d606c1d4165438 (diff)
Input: add option to disable HP SDC driver
Add "no_hpsdc" kernel module option to the hp_sdc driver, so that the driver can be instructed to not enable the HP SDC port. This is useful on some older HPPA boxes with HIL keyboard and HIL mouse where the new HP SDC HIL drivers don't work yet. By disabling the new hp_sdc driver users are able to use the older hilkbd driver instead. Signed-off-by: Helge Deller <deller@gmx.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/serio/hp_sdc.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/input/serio/hp_sdc.c b/drivers/input/serio/hp_sdc.c
index edfedd9a166c..7b233a492ad5 100644
--- a/drivers/input/serio/hp_sdc.c
+++ b/drivers/input/serio/hp_sdc.c
@@ -105,6 +105,10 @@ EXPORT_SYMBOL(__hp_sdc_enqueue_transaction);
105EXPORT_SYMBOL(hp_sdc_enqueue_transaction); 105EXPORT_SYMBOL(hp_sdc_enqueue_transaction);
106EXPORT_SYMBOL(hp_sdc_dequeue_transaction); 106EXPORT_SYMBOL(hp_sdc_dequeue_transaction);
107 107
108static unsigned int hp_sdc_disabled;
109module_param_named(no_hpsdc, hp_sdc_disabled, bool, 0);
110MODULE_PARM_DESC(no_hpsdc, "Do not enable HP SDC driver.");
111
108static hp_i8042_sdc hp_sdc; /* All driver state is kept in here. */ 112static hp_i8042_sdc hp_sdc; /* All driver state is kept in here. */
109 113
110/*************** primitives for use in any context *********************/ 114/*************** primitives for use in any context *********************/
@@ -980,6 +984,11 @@ static int __init hp_sdc_register(void)
980 unsigned char i; 984 unsigned char i;
981#endif 985#endif
982 986
987 if (hp_sdc_disabled) {
988 printk(KERN_WARNING PREFIX "HP SDC driver disabled by no_hpsdc=1.\n");
989 return -ENODEV;
990 }
991
983 hp_sdc.dev = NULL; 992 hp_sdc.dev = NULL;
984 hp_sdc.dev_err = 0; 993 hp_sdc.dev_err = 0;
985#if defined(__hppa__) 994#if defined(__hppa__)