Commit 594765a7316562cb7442f760a9a2f6e02804b610
Committed by
Bartlomiej Zolnierkiewicz
1 parent
b004223db7
Exists in
master
and in
7 other branches
ide-pci-generic: kill the unused ifdef/endif/MODULE code
with module_param macro, the __setup code can be killed now: const __setup("all-generic-ide", ide_generic_all_on); and the module name "generic.ko" is not descriptive to its functionality, can be changed in Makefile, the "ide-pci-generic.ko" is better. the ide-pci-generic.all-generic-ide parameter also documented in Documentation/kernel-parameters.txt Signed-off-by: Denis Cheng <crquan@gmail.com> Cc: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Showing 3 changed files with 5 additions and 14 deletions Side-by-side Diff
Documentation/kernel-parameters.txt
... | ... | @@ -780,6 +780,9 @@ |
780 | 780 | loop use the MONITOR/MWAIT idle loop anyways. Performance should be the same |
781 | 781 | as idle=poll. |
782 | 782 | |
783 | + ide-pci-generic.all-generic-ide [HW] (E)IDE subsystem | |
784 | + Claim all unknown PCI IDE storage controllers. | |
785 | + | |
783 | 786 | ignore_loglevel [KNL] |
784 | 787 | Ignore loglevel setting - this will print /all/ |
785 | 788 | kernel messages to the console. Useful for debugging. |
drivers/ide/pci/Makefile
... | ... | @@ -34,7 +34,8 @@ |
34 | 34 | obj-$(CONFIG_BLK_DEV_VIA82CXXX) += via82cxxx.o |
35 | 35 | |
36 | 36 | # Must appear at the end of the block |
37 | -obj-$(CONFIG_BLK_DEV_GENERIC) += generic.o | |
37 | +obj-$(CONFIG_BLK_DEV_GENERIC) += ide-pci-generic.o | |
38 | +ide-pci-generic-y += generic.o | |
38 | 39 | |
39 | 40 | ifeq ($(CONFIG_BLK_DEV_CMD640), m) |
40 | 41 | obj-m += cmd640.o |
drivers/ide/pci/generic.c
... | ... | @@ -29,19 +29,6 @@ |
29 | 29 | |
30 | 30 | static int ide_generic_all; /* Set to claim all devices */ |
31 | 31 | |
32 | -/* | |
33 | - * the module_param_named() was added for the modular case | |
34 | - * the __setup() is left as compatibility for existing setups | |
35 | - */ | |
36 | -#ifndef MODULE | |
37 | -static int __init ide_generic_all_on(char *unused) | |
38 | -{ | |
39 | - ide_generic_all = 1; | |
40 | - printk(KERN_INFO "IDE generic will claim all unknown PCI IDE storage controllers.\n"); | |
41 | - return 1; | |
42 | -} | |
43 | -const __setup("all-generic-ide", ide_generic_all_on); | |
44 | -#endif | |
45 | 32 | module_param_named(all_generic_ide, ide_generic_all, bool, 0444); |
46 | 33 | MODULE_PARM_DESC(all_generic_ide, "IDE generic will claim all unknown PCI IDE storage controllers."); |
47 | 34 |