Name: Remove alias references Author: Rusty Russell Status: Trivial Add more MODULE_ALIASes, and remove references to them from documentaiton. Also, remove module alias from bttv: Debian includes the alias, but it must be the user's decision which one of the several video drivers to load for char-major-81-0 etc. Index: linux-2.6.10-bk14-Module/drivers/char/ftape/zftape/zftape-init.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/char/ftape/zftape/zftape-init.c 2005-01-12 13:08:31.000000000 +1100 +++ linux-2.6.10-bk14-Module/drivers/char/ftape/zftape/zftape-init.c 2005-01-12 13:28:43.891121912 +1100 @@ -52,7 +52,7 @@ "VFS interface for the Linux floppy tape driver. " "Support for QIC-113 compatible volume table " "and builtin compression (lzrw3 algorithm)"); -MODULE_SUPPORTED_DEVICE("char-major-27"); +MODULE_ALIAS_CHARDEV_MAJOR(QIC117_TAPE_MAJOR); MODULE_LICENSE("GPL"); /* Global vars. Index: linux-2.6.10-bk14-Module/drivers/char/pcxx.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/char/pcxx.c 2004-12-28 12:30:17.000000000 +1100 +++ linux-2.6.10-bk14-Module/drivers/char/pcxx.c 2005-01-12 13:28:43.858126928 +1100 @@ -119,7 +119,7 @@ module_param_array(memsize, int, NULL, 0); module_param_array(altpin, int, NULL, 0); module_param_array(numports, int, NULL, 0); - +MODULE_ALIAS_CHARDEV_MAJOR(DIGI_MAJOR); #endif /* MODULE */ static int numcards = 1; Index: linux-2.6.10-bk14-Module/drivers/media/video/videodev.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/media/video/videodev.c 2004-10-19 14:34:01.000000000 +1000 +++ linux-2.6.10-bk14-Module/drivers/media/video/videodev.c 2005-01-12 13:28:43.919117656 +1100 @@ -436,7 +436,7 @@ MODULE_AUTHOR("Alan Cox"); MODULE_DESCRIPTION("Device registrar for Video4Linux drivers"); MODULE_LICENSE("GPL"); - +MODULE_ALIAS_CHARDEV_MAJOR(VIDEO_DEV); /* * Local variables: Index: linux-2.6.10-bk14-Module/include/sound/minors.h =================================================================== --- linux-2.6.10-bk14-Module.orig/include/sound/minors.h 2004-02-18 23:54:35.000000000 +1100 +++ linux-2.6.10-bk14-Module/include/sound/minors.h 2005-01-12 13:28:43.934115376 +1100 @@ -84,6 +84,8 @@ #define MODULE_ALIAS_SNDRV_MINOR(type) \ MODULE_ALIAS("sound-service-?-" __stringify(type)) +#define MODULE_ALIAS_SNDRV_MINOR(type) \ + MODULE_ALIAS("sound-service-?-" __stringify(type)) #endif #endif /* __SOUND_MINORS_H */ Index: linux-2.6.10-bk14-Module/Documentation/hayes-esp.txt =================================================================== --- linux-2.6.10-bk14-Module.orig/Documentation/hayes-esp.txt 2004-03-12 07:56:34.000000000 +1100 +++ linux-2.6.10-bk14-Module/Documentation/hayes-esp.txt 2005-01-12 13:28:43.989107016 +1100 @@ -48,9 +48,9 @@ The address in brackets is the base address of the card. The IRQ of nonexistent cards can be set to 0. If an IRQ of a card that does exist is set to 0, the driver will attempt to guess at the correct IRQ. For example, to set -the IRQ of the card at address 0x300 to 12, the insmod command would be: +the IRQ of the card at address 0x300 to 12, the modprobe command would be: -insmod esp irq=0,0,0,0,0,0,12,0 +modprobe esp irq=0,0,0,0,0,0,12,0 The custom divisor can be set by using the divisor= option. The format is the same as for the irq= option. Each divisor value is a series of hex digits, Index: linux-2.6.10-bk14-Module/Documentation/sound/oss/Opti =================================================================== --- linux-2.6.10-bk14-Module.orig/Documentation/sound/oss/Opti 2004-03-12 07:56:35.000000000 +1100 +++ linux-2.6.10-bk14-Module/Documentation/sound/oss/Opti 2005-01-12 13:28:43.963110968 +1100 @@ -97,9 +97,9 @@ alias midi0 mad16 alias synth0 opl3 -When any sound device is opened the kernel requests auto-loading -of char-major-14. There is a built-in alias that translates this -request to loading the main sound module. +When any sound device is opened the kernel requests auto-loading of +char-major-14. This loads the main sound module by default, but can +be overriden in /etc/modprobe.conf. The sound module in its turn will request loading of a sub-driver for mixer, audio, midi or synthesizer device. The first 3 are @@ -120,7 +120,7 @@ options mad16 irq=10 dma=0 dma16=1 io=0x530 joystick=1 cdtype=0 options opl3 io=0x388 -post-install mad16 /sbin/ad1848_mixer_reroute 14 8 15 3 16 6 +install mad16 /sbin/modprobe --ignore-install mad16 && /sbin/ad1848_mixer_reroute 14 8 15 3 16 6 This sets resources and options for the mad16 and opl3 drivers. I use two DMA channels (only one is required) to enable full duplex. Index: linux-2.6.10-bk14-Module/drivers/char/rocket.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/char/rocket.c 2004-12-28 12:30:17.000000000 +1100 +++ linux-2.6.10-bk14-Module/drivers/char/rocket.c 2005-01-12 13:28:44.038099568 +1100 @@ -222,6 +222,10 @@ MODULE_LICENSE("Dual BSD/GPL"); #endif +#ifdef MODULE_ALIAS_CHARDEV_MAJOR +MODULE_ALIAS_CHARDEV_MAJOR(TTY_ROCKET_MAJOR); +#endif + /*************************************************************************/ /* Module code starts here */ Index: linux-2.6.10-bk14-Module/drivers/char/ip2.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/char/ip2.c 2004-12-28 12:30:16.000000000 +1100 +++ linux-2.6.10-bk14-Module/drivers/char/ip2.c 2005-01-12 13:28:44.007104280 +1100 @@ -45,6 +45,9 @@ module_param(poll_only, bool, 0); MODULE_PARM_DESC(poll_only,"Do not use card interrupts"); +MODULE_ALIAS_CHARDEV_MAJOR(IP2_IPL_MAJOR); +MODULE_ALIAS_CHARDEV_MAJOR(IP2_TTY_MAJOR); +MODULE_ALIAS_CHARDEV_MAJOR(IP2_CALLOUT_MAJOR); static int __init ip2_init(void) { Index: linux-2.6.10-bk14-Module/drivers/input/input.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/input/input.c 2005-01-12 13:08:35.000000000 +1100 +++ linux-2.6.10-bk14-Module/drivers/input/input.c 2005-01-12 13:28:44.094091056 +1100 @@ -27,6 +27,7 @@ MODULE_AUTHOR("Vojtech Pavlik "); MODULE_DESCRIPTION("Input core"); MODULE_LICENSE("GPL"); +MODULE_ALIAS_CHARDEV_MAJOR(INPUT_MAJOR); EXPORT_SYMBOL(input_register_device); EXPORT_SYMBOL(input_unregister_device); Index: linux-2.6.10-bk14-Module/drivers/char/esp.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/char/esp.c 2004-12-28 12:30:16.000000000 +1100 +++ linux-2.6.10-bk14-Module/drivers/char/esp.c 2005-01-12 13:28:44.061096072 +1100 @@ -96,6 +96,9 @@ module_param(rx_timeout, uint, 0); module_param(pio_threshold, uint, 0); +MODULE_ALIAS_CHARDEV_MAJOR(ESP_IN_MAJOR); +MODULE_ALIAS_CHARDEV_MAJOR(ESP_OUT_MAJOR); /* hayes-esp claimed this, too? */ + /* END */ static char *dma_buffer; Index: linux-2.6.10-bk14-Module/include/linux/device.h =================================================================== --- linux-2.6.10-bk14-Module.orig/include/linux/device.h 2005-01-12 13:09:10.000000000 +1100 +++ linux-2.6.10-bk14-Module/include/linux/device.h 2005-01-12 13:28:44.125086344 +1100 @@ -421,5 +421,5 @@ #define MODULE_ALIAS_CHARDEV(major,minor) \ MODULE_ALIAS("char-major-" __stringify(major) "-" __stringify(minor)) #define MODULE_ALIAS_CHARDEV_MAJOR(major) \ - MODULE_ALIAS("char-major-" __stringify(major) "-*") + MODULE_ALIAS("char-major-" __stringify(major) "*") #endif /* _DEVICE_H_ */ Index: linux-2.6.10-bk14-Module/drivers/i2c/i2c-dev.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/i2c/i2c-dev.c 2004-12-28 12:30:19.000000000 +1100 +++ linux-2.6.10-bk14-Module/drivers/i2c/i2c-dev.c 2005-01-12 13:28:44.209073576 +1100 @@ -555,6 +555,7 @@ "Simon G. Vogl "); MODULE_DESCRIPTION("I2C /dev entries driver"); MODULE_LICENSE("GPL"); +MODULE_ALIAS_CHARDEV_MAJOR(I2C_MAJOR); module_init(i2c_dev_init); module_exit(i2c_dev_exit); Index: linux-2.6.10-bk14-Module/drivers/scsi/osst.c =================================================================== --- linux-2.6.10-bk14-Module.orig/drivers/scsi/osst.c 2004-12-28 12:30:42.000000000 +1100 +++ linux-2.6.10-bk14-Module/drivers/scsi/osst.c 2005-01-12 13:28:44.188076768 +1100 @@ -5647,3 +5647,4 @@ module_init(init_osst); module_exit(exit_osst); +MODULE_ALIAS_CHARDEV_MAJOR(OSST_MAJOR);