Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: comedi: remove 'comedi_autoconfig' module parameter

This module parameter is used to enable the auto config mechanism
in the comedi core. Most of the PCI, PCMCIA, and USB drivers have
been converted to use the auto config mechanism and will not attach
if it is disabled.

Since the 'comedi_autoconfig' parameter is defaulted to true, just
remove it so that the comedi drivers that use auto config will
always be able to attach.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

H Hartley Sweeten and committed by
Greg Kroah-Hartman
4a79f730 bd7807f9

+1 -24
-13
drivers/staging/comedi/comedi_fops.c
··· 58 58 ); 59 59 #endif 60 60 61 - bool comedi_autoconfig = true; 62 - module_param(comedi_autoconfig, bool, S_IRUGO); 63 - MODULE_PARM_DESC(comedi_autoconfig, 64 - "enable drivers to auto-configure comedi devices (default 1)"); 65 - 66 61 static int comedi_num_legacy_minors; 67 62 module_param(comedi_num_legacy_minors, int, S_IRUGO); 68 63 MODULE_PARM_DESC(comedi_num_legacy_minors, ··· 2431 2436 COMEDI_NUM_BOARD_MINORS); 2432 2437 return -EINVAL; 2433 2438 } 2434 - 2435 - /* 2436 - * comedi is unusable if both comedi_autoconfig and 2437 - * comedi_num_legacy_minors are zero, so we might as well adjust the 2438 - * defaults in that case 2439 - */ 2440 - if (!comedi_autoconfig && comedi_num_legacy_minors == 0) 2441 - comedi_num_legacy_minors = 16; 2442 2439 2443 2440 memset(comedi_file_info_table, 0, 2444 2441 sizeof(struct comedi_file_info *) * COMEDI_NUM_MINORS);
-1
drivers/staging/comedi/comedi_internal.h
··· 21 21 22 22 extern unsigned int comedi_default_buf_size_kb; 23 23 extern unsigned int comedi_default_buf_maxsize_kb; 24 - extern bool comedi_autoconfig; 25 24 26 25 /* drivers.c */ 27 26
-3
drivers/staging/comedi/drivers.c
··· 410 410 struct comedi_device *comedi_dev; 411 411 int ret; 412 412 413 - if (!comedi_autoconfig) 414 - return 0; 415 - 416 413 if (!driver->auto_attach) { 417 414 dev_warn(hardware_device, 418 415 "BUG! comedi driver '%s' has no auto_attach handler\n",
+1 -7
drivers/staging/comedi/drivers/adl_pci7x3x.c
··· 38 38 Updated: Thu, 02 Aug 2012 14:27:46 -0700 39 39 Status: untested 40 40 41 - This driver only attaches using the PCI PnP auto config support 42 - in the comedi core. The module parameter 'comedi_autoconfig' 43 - must be 1 (default) to enable this feature. The COMEDI_DEVCONFIG 44 - ioctl, used by the comedi_config utility, is not supported by 45 - this driver. 46 - 47 41 The PCI-7230, PCI-7432 and PCI-7433 boards also support external 48 42 interrupt signals on digital input channels 0 and 1. The PCI-7233 49 43 has dual-interrupt sources for change-of-state (COS) on any 16 ··· 45 51 lines of MSB. Interrupts are not currently supported by this 46 52 driver. 47 53 48 - Configuration Options: not applicable 54 + Configuration Options: not applicable, uses comedi PCI auto config 49 55 */ 50 56 51 57 #include <linux/pci.h>