21 Jan, 2009

1 commit


15 Oct, 2008

1 commit


13 Oct, 2008

1 commit

  • This makes modpost handle MODULE_DEVICE_TABLE(dmi, xxxx).

    I had to change the string pointers in the match table to char arrays,
    and picked a size of 79 bytes almost at random -- do we need to make it
    bigger than that? I was a bit concerned about the 'bloat' this
    introduces into the match tables, but they should all be __initdata so
    it shouldn't matter too much.

    (Actually, modpost does go through the relocations and look at most of
    them; it wouldn't be impossible to make it handle string pointers -- but
    doesn't seem to be worth the effort, since they're __initdata).

    Signed-off-by: David Woodhouse

    David Woodhouse
     

22 Aug, 2008

1 commit


25 Jul, 2008

1 commit

  • Trying to compile the v850 port brings many compile errors, one of them exists
    since at least kernel 2.6.19.

    There also seems to be noone willing to bring this port back into a usable
    state.

    This patch therefore removes the v850 port.

    If anyone ever decides to revive the v850 port the code will still be
    available from older kernels, and it wouldn't be impossible for the port to
    reenter the kernel if it would become actively maintained again.

    Signed-off-by: Adrian Bunk
    Acked-by: Greg Ungerer
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Adrian Bunk
     

22 Jul, 2008

1 commit

  • Along with the non-modalias conformant "pnp:*" aliases, we add "acpi:*"
    entries to PNP drivers, to allow module autoloading by ACPI PNP device
    entries, which export proper modalias information, without any specific
    userspace modprobe mangling.

    Cc: Adam Belay
    Cc: Thomas Renninger
    Signed-off-by: Kay Sievers
    Signed-off-by: Greg Kroah-Hartman

    Kay Sievers
     

14 Jul, 2008

1 commit

  • Add modalias and subchannel type attributes for all subchannels.
    I/O subchannel specific attributes are now created in
    io_subchannel_probe(). modalias and subchannel type are also
    added to the uevent for the css bus. Also make the css modalias
    known.

    Signed-off-by: Cornelia Huck
    Signed-off-by: Martin Schwidefsky
    Signed-off-by: Heiko Carstens

    Cornelia Huck
     

04 May, 2008

1 commit

  • Not all device types need a wildcard at the end of their module
    aliases. In particular, for i2c module aliases, the trailing wildcard
    is not only unneeded, it could also cause the wrong driver to be
    loaded.

    As I2C devices have no IDs, i2c module aliases are simple, arbitrary
    device names. For example:

    $ /sbin/modinfo lm90
    filename: /lib/modules/2.6.25-git18/kernel/drivers/hwmon/lm90.ko
    author: Jean Delvare
    description: LM90/ADM1032 driver
    license: GPL
    vermagic: 2.6.25-git18 mod_unload
    depends: hwmon
    alias: i2c:lm90*
    alias: i2c:adm1032*
    alias: i2c:lm99*
    alias: i2c:lm86*
    alias: i2c:max6657*
    alias: i2c:adt7461*
    alias: i2c:max6680*
    $

    This would cause trouble if one I2C chip name matches the beginning of
    another I2C chip name and both chips are supported by different
    drivers. For example, an i2c device named lm9042 would cause the lm90
    driver to be loaded, while it doesn't support that device. This case
    has yet to be seen in practice, but still, I'd like to fix it now. The
    cleanest fix is to remove the trailing wildcard from i2c module aliases.

    Here's a patch doing this.

    Not all device type aliases need a trailing wildcard, in particular
    the i2c aliases don't. Don't add a wildcard by default in do_table(),
    instead let each device type handler add it if needed.

    I have tested types acpi, dmi, eisa, i2c, ide, ieee1394, input, pci,
    pcmcia, platform, pnp, scsi, serio, ssb and usb. Other types (ccw, of,
    vio, parisc, sdio and virtio) are untested.
    Signed-off-by: Jean Delvare
    Acked-by: Jochen Friedrich
    Signed-off-by: Sam Ravnborg

    Jean Delvare
     

30 Apr, 2008

1 commit

  • Based on earlier work by Jon Smirl and Jochen Friedrich.

    This patch allows new-style i2c chip drivers to have alias names using
    the official kernel aliasing system and MODULE_DEVICE_TABLE(). At this
    point, the old i2c driver binding scheme (driver_name/type) is still
    supported.

    Signed-off-by: Jean Delvare
    Cc: Jochen Friedrich
    Cc: Jon Smirl
    Cc: Kay Sievers

    Jean Delvare
     

20 Apr, 2008

1 commit

  • The current PNP combined card + devices module aliase can
    never ever match anything, because these values are not available
    all at the same time to request a module.

    Instead of adding the combined alias, we add the device id's
    all as individual aliases. Device id's are exported by the PNP
    bus and can now properly used to request the loading of a
    matching module.

    The module snd-sbawe currently exports aliases, which can never
    match anything:
    alias: pnp:cCTLXXXXdCTL0045dCTL0022*
    alias: pnp:cCTLXXXXdCTL0044dCTL0023*
    alias: pnp:cCTLXXXXdCTL0042dCTL0022*
    alias: pnp:cCTLXXXXdCTL0041dCTL0021*
    alias: pnp:cCTLXXXXdCTL0031dCTL0021*
    alias: pnp:cCTL00eddCTL0041dCTL0070*
    alias: pnp:cCTL00e9dCTL0045dCTL0022*
    alias: pnp:cCTL00e4dCTL0045dCTL0022*
    alias: pnp:cCTL00c7dCTL0045dCTL0022*
    alias: pnp:cCTL00c5dCTL0045dCTL0022*
    alias: pnp:cCTL00c3dCTL0045dCTL0022*
    alias: pnp:cCTL00c1dCTL0042dCTL0022*
    alias: pnp:cCTL00b2dCTL0044dCTL0023*
    alias: pnp:cCTL009edCTL0044dCTL0023*
    alias: pnp:cCTL009ddCTL0042dCTL0022*
    alias: pnp:cCTL009fdCTL0041dCTL0021*
    alias: pnp:cCTL009cdCTL0041dCTL0021*
    alias: pnp:cCTL009adCTL0041dCTL0021*
    alias: pnp:cCTL0054dCTL0031dCTL0021*
    alias: pnp:cCTL0048dCTL0031dCTL0021*
    alias: pnp:cCTL0047dCTL0031dCTL0021*
    alias: pnp:cCTL0046dCTL0031dCTL0021*
    alias: pnp:cCTL0045dCTL0031dCTL0021*
    alias: pnp:cCTL0044dCTL0031dCTL0021*
    alias: pnp:cCTL0043dCTL0031dCTL0021*
    alias: pnp:cCTL0042dCTL0031dCTL0021*
    alias: pnp:cCTL0039dCTL0031dCTL0021*
    alias: pnp:cCTL0035dCTL0031dCTL0021*

    With this patch it exports only the device id's, as properly
    matchable aliases:
    alias: pnp:dCTL0070*
    alias: pnp:dCTL0045*
    alias: pnp:dCTL0023*
    alias: pnp:dCTL0044*
    alias: pnp:dCTL0022*
    alias: pnp:dCTL0042*
    alias: pnp:dCTL0041*
    alias: pnp:dCTL0021*
    alias: pnp:dCTL0031*

    Now, the exported value of the PNP bus can be used to autoload
    a matching module:
    $ modprobe --first-time -n -v pnp:dCTL0045
    insmod /lib/modules/2.6.24-rc6-g5b825ed2-dirty/kernel/sound/core/snd-rawmidi.ko
    insmod /lib/modules/2.6.24-rc6-g5b825ed2-dirty/kernel/sound/drivers/mpu401/snd-mpu401-uart.ko
    insmod /lib/modules/2.6.24-rc6-g5b825ed2-dirty/kernel/sound/core/snd-hwdep.ko
    insmod /lib/modules/2.6.24-rc6-g5b825ed2-dirty/kernel/sound/isa/sb/snd-sb-common.ko
    insmod /lib/modules/2.6.24-rc6-g5b825ed2-dirty/kernel/sound/isa/sb/snd-sb16-csp.ko
    insmod /lib/modules/2.6.24-rc6-g5b825ed2-dirty/kernel/sound/isa/sb/snd-sb16-dsp.ko
    insmod /lib/modules/2.6.24-rc6-g5b825ed2-dirty/kernel/sound/drivers/opl3/snd-opl3-lib.ko
    insmod /lib/modules/2.6.24-rc6-g5b825ed2-dirty/kernel/sound/isa/sb/snd-sbawe.ko

    $ grep CTL0045 /sys/bus/pnp/devices/*/id
    /sys/bus/pnp/devices/01:01.00/id:CTL0045

    Signed-off-by: Kay Sievers
    Signed-off-by: Greg Kroah-Hartman

    Kay Sievers
     

24 Mar, 2008

1 commit

  • The module alias support in the kernel have a consistency
    check where it is checked that the size of a structure
    in the kernel and on the build host are the same.
    For cross builds this check does not make sense so detect
    when we do cross builds and silently skip the check in these
    situations.
    This fixes a build bug for a wireless driver when cross building
    for arm.

    Acked-by: Michael Buesch
    Tested-by: Gordon Farquharson
    Signed-off-by: Sam Ravnborg
    Cc: stable@kernel.org

    Sam Ravnborg
     

02 Feb, 2008

1 commit

  • Some crazy devices in the wild have a vendor id of 0x0000. If we try to
    add a module alias with this id, we just can't do it due to a check in
    the file2alias.c file. Change the test to verify that both the vendor
    and product ids are 0x0000 to show a real "blank" module alias.

    Note, the module-init-tools package also needs to be changed to properly
    generate the depmod tables.

    Cc: Janusz
    Cc: stable
    Cc: Jon Masters
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     

23 Oct, 2007

1 commit


17 Oct, 2007

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild: (40 commits)
    kbuild: introduce ccflags-y, asflags-y and ldflags-y
    kbuild: enable 'make CPPFLAGS=...' to add additional options to CPP
    kbuild: enable use of AFLAGS and CFLAGS on commandline
    kbuild: enable 'make AFLAGS=...' to add additional options to AS
    kbuild: fix AFLAGS use in h8300 and m68knommu
    kbuild: check for wrong use of CFLAGS
    kbuild: enable 'make CFLAGS=...' to add additional options to CC
    kbuild: fix up CFLAGS usage
    kbuild: make modpost detect unterminated device id lists
    kbuild: call export_report from the Makefile
    kbuild: move Kai Germaschewski to CREDITS
    kconfig/menuconfig: distinguish between selected-by-another options and comments
    kconfig: tristate choices with mixed tristate and boolean values
    include/linux/Kbuild: remove duplicate entries
    kbuild: kill backward compatibility checks
    kbuild: kill EXTRA_ARFLAGS
    kbuild: fix documentation in makefiles.txt
    kbuild: call make once for all targets when O=.. is used
    kbuild: pass -g to assembler under CONFIG_DEBUG_INFO
    kbuild: update _shipped files for kconfig syntax cleanup
    ...

    Fix up conflicts in arch/um/sys-{x86_64,i386}/Makefile manually.

    Linus Torvalds
     

14 Oct, 2007

1 commit

  • I2C devices do not have any form of ID as PCI or USB devices have.
    No driver uses "MODULE_DEVICE_TABLE(i2c, ...)" because it doesn't
    make sense. So we can get rid of struct i2c_device_id and the
    associated support code.

    Signed-off-by: Jean Delvare
    Cc: Greg KH

    Jean Delvare
     

13 Oct, 2007

1 commit

  • Cause modpost to fail if any device id lists are incorrectly terminated,
    after reporting the offender.
    Improved reporting by akpm

    Signed-off-by: Kees Cook
    Cc: Greg KH
    Cc: Alexey Dobriyan
    Cc: Jeff Garzik
    Cc: Ben Collins
    Cc: Michael Wu
    Cc: Rusty Russell
    Signed-off-by: Andrew Morton
    Signed-off-by: Sam Ravnborg

    Kees Cook
     

12 Oct, 2007

1 commit

  • * 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (867 commits)
    [SKY2]: status polling loop (post merge)
    [NET]: Fix NAPI completion handling in some drivers.
    [TCP]: Limit processing lost_retrans loop to work-to-do cases
    [TCP]: Fix lost_retrans loop vs fastpath problems
    [TCP]: No need to re-count fackets_out/sacked_out at RTO
    [TCP]: Extract tcp_match_queue_to_sack from sacktag code
    [TCP]: Kill almost unused variable pcount from sacktag
    [TCP]: Fix mark_head_lost to ignore R-bit when trying to mark L
    [TCP]: Add bytes_acked (ABC) clearing to FRTO too
    [IPv6]: Update setsockopt(IPV6_MULTICAST_IF) to support RFC 3493, try2
    [NETFILTER]: x_tables: add missing ip6t_modulename aliases
    [NETFILTER]: nf_conntrack_tcp: fix connection reopening
    [QETH]: fix qeth_main.c
    [NETLINK]: fib_frontend build fixes
    [IPv6]: Export userland ND options through netlink (RDNSS support)
    [9P]: build fix with !CONFIG_SYSCTL
    [NET]: Fix dev_put() and dev_hold() comments
    [NET]: make netlink user -> kernel interface synchronious
    [NET]: unify netlink kernel socket recognition
    [NET]: cleanup 3rd argument in netlink_sendskb
    ...

    Fix up conflicts manually in Documentation/feature-removal-schedule.txt
    and my new least favourite crap, the "mod_devicetable" support in the
    files include/linux/mod_devicetable.h and scripts/mod/file2alias.c.

    (The latter files seem to be explicitly _designed_ to get conflicts when
    different subsystems work with them - that have an absolutely horrid
    lack of subsystem separation!)

    Signed-off-by: Linus Torvalds

    Linus Torvalds
     

11 Oct, 2007

1 commit

  • SSB is an SoC bus used in a number of embedded devices. The most
    well-known of these devices is probably the Linksys WRT54G, but there
    are others as well. The bus is also used internally on the BCM43xx
    and BCM44xx devices from Broadcom.

    This patch also includes support for SSB ID tables in modules, so
    that SSB drivers can be loaded automatically.

    Signed-off-by: Michael Buesch
    Signed-off-by: John W. Linville
    Signed-off-by: David S. Miller

    Michael Buesch
     

24 Sep, 2007

1 commit


24 Jul, 2007

1 commit

  • Modify modpost (file2alias.c) to add acpi*:XYZ0001: alias in modules.alias
    like:
    grep acpi /lib/modules/2.6.22-rc4-default/modules.alias
    alias acpi*:SNY5001:* sony_laptop
    alias acpi*:SNY6001:* sony_laptop
    for e.g. the sony_laptop module.
    This module matches against all ACPI devices with a HID or CID of SNY5001
    or SNY6001

    Export an uevent and modalias sysfs file containing the string:
    [MODALIAS=]acpi:PNP0C0C:
    additional CIDs are concatenated at the end.

    Signed-off-by: Thomas Renninger
    Signed-off-by: Kay Sievers
    Signed-off-by: Len Brown

    Thomas Renninger
     

19 May, 2007

1 commit

  • Since the devices may have multiple (or none) compatible properties,
    the uevent generated internally by the kernel may have multiple
    "C..." entries. So the MODALIAS stored in the module must have
    wilcard before and after the compatible entry.
    Also, if the 'compatible' field is not used for matching, there
    will be no 'C' and that must handled as well.

    The previous code handled all those case incorrectly and it
    "mostly" worked ... but not always.

    Signed-off-by: Sylvain Munaut
    Signed-off-by: Paul Mackerras
    Signed-off-by: Sam Ravnborg

    Sylvain Munaut
     

03 May, 2007

1 commit


17 Feb, 2007

2 commits


27 Sep, 2006

1 commit

  • Add modalias attribute support for the almost forgotten now EISA bus and
    (at least some) EISA-aware modules.

    The modalias entry looks like (for an 3c509 NIC):

    eisa:sTCM5093

    and the in-module alias like:

    eisa:sTCM5093*

    The patch moves struct eisa_device_id declaration from include/linux/eisa.h
    to include/linux/mod_devicetable.h (so that the former now #includes the
    latter), adds proper MODULE_DEVICE_TABLE(eisa, ...) statements for all
    drivers with EISA IDs I found (some drivers already have that DEVICE_TABLE
    declared), and adds recognision of __mod_eisa_device_table to
    scripts/mod/file2alias.c so that proper modules.alias will be generated.

    There's no support for /lib/modules/$kver/modules.eisamap, as it's not used
    by any existing tools, and because with in-kernel modalias mechanism those
    maps are obsolete anyway.

    The rationale for this patch is:

    a) to make EISA bus to act as other busses with modalias
    support, to unify driver loading

    b) to foget about EISA finally - with this patch, kernel
    (who still supports EISA) will be the only one who knows
    how to choose the necessary drivers for this bus ;)

    [akpm@osdl.org: fix the kbuild bit]
    Signed-off-by: Michael Tokarev
    Cc: Rusty Russell
    Cc: Randy Dunlap
    Acked-the-net-bits-by: Jeff Garzik
    Acked-the-tulip-bit-by: Valerie Henson
    Cc: James Bottomley
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Michael Tokarev
     

20 Sep, 2006

1 commit

  • Add a bus for the adjunct processor interface. Up to 64 devices can
    be connect to the ap bus interface, each device with 16 domains. That
    makes 1024 message queues. The interface is asynchronous, the answer
    to a message sent to a queue needs to be received at some later point
    in time. Unfortunately the interface does not provide interrupts when
    a message reply is pending. So the ap bus needs to implement some
    fancy polling, each active queue is polled once per 1/HZ second or
    continuously if an idle cpus exsists and the poll thread is activ
    (see poll_thread parameter).

    The ap bus uses the sysfs path /sys/bus/ap and has two bus attributes,
    ap_domain and config_time. The ap_domain selects one of the 16 domains
    to be used for this system. This limits the maximum number of ap devices
    to 64. The config_time attribute contains the number of seconds between
    two ap bus scans to find new devices.

    The ap bus uses the modalias entries of the form "ap:tN" to autoload
    the ap driver for hardware type N. Currently known types are:
    3 - PCICC, 4 - PCICA, 5 - PCIXCC, 6 - CEX2A and 7 - CEX2C.

    Signed-off-by: Cornelia Huck
    Signed-off-by: Ralph Wuerthner
    Signed-off-by: Martin Schwidefsky

    Martin Schwidefsky
     

16 Aug, 2006

1 commit

  • There is a small but annoying bug in scripts/mod/file2alias.c which causes
    it to generate invalid aliases for input devices on 64 bit archs. This causes
    joydev.ko to not be automaticly loaded when inserting a joystick, resulting in
    a non working joystick (for the average user).

    In scripts/mod/file2alias.c is the following code for generating the input
    aliases:
    static void do_input(char *alias,
    kernel_ulong_t *arr, unsigned int min, unsigned int max)
    {
    unsigned int i;

    for (i = min; i < max; i++)
    if (arr[i / BITS_PER_LONG] & (1 << (i%BITS_PER_LONG)))
    sprintf(alias + strlen(alias), "%X,*", i);
    }

    On 32 bits systems, this correctly generates "0,*" for the first alias, "8,*"
    for the second etc.

    However on 64 bits it generates: "0,*20,*" resp "8,*28,*" Notice how it adds 20
    + first entry (hex) ! to the list of hex codes, which is 32 more then the first
    entry, thus is because the bit test above wraps at 32 bits instead of 64.

    scripts/mod/file2alias.c, line 379 reads:
    if (arr[i / BITS_PER_LONG] & (1 << (i%BITS_PER_LONG)))
    That should be:
    if (arr[i / BITS_PER_LONG] & (1L << (i%BITS_PER_LONG)))

    Notice the added 'L' after the 1, otherwise that is an 32 bit int instead of a
    64 bit long, and when that int gets shifted >= 32 times, appearantly the number
    by which to shift is wrapped at 5 bits ( % 32) causing it to test a bit 32 bits
    too low.

    The patch below makes the nescesarry 1 char change :)

    Signed-off-by: Hans de Goede
    Acked-by: Rusty Russell
    Signed-off-by: Greg Kroah-Hartman

    Hans de Goede
     

01 Aug, 2006

1 commit

  • The original errormessage was just plain unreadable.

    Sample error message after this update (not for real - I provoked it):

    FATAL: drivers/net/s2io: sizeof(struct pci_device_id)=33 is not a modulo of the
    size of section __mod_pci_device_table=160.
    Fix definition of struct pci_device_id in mod_devicetable.h

    Before a warning was generated - this is now a fatal error.

    Signed-off-by: Sam Ravnborg

    Sam Ravnborg
     

26 Apr, 2006

1 commit


26 Mar, 2006

1 commit

  • * master.kernel.org:/pub/scm/linux/kernel/git/sam/kbuild: (46 commits)
    kbuild: remove obsoleted scripts/reference_* files
    kbuild: fix make help & make *pkg
    kconfig: fix time ordering of writes to .kconfig.d and include/linux/autoconf.h
    Kconfig: remove the CONFIG_CC_ALIGN_* options
    kbuild: add -fverbose-asm to i386 Makefile
    kbuild: clean-up genksyms
    kbuild: Lindent genksyms.c
    kbuild: fix genksyms build error
    kbuild: in makefile.txt note that Makefile is preferred name for kbuild files
    kbuild: replace PHONY with FORCE
    kbuild: Fix bug in crc symbol generating of kernel and modules
    kbuild: change kbuild to not rely on incorrect GNU make behavior
    kbuild: when warning symbols exported twice now tell user this is the problem
    kbuild: fix make dir/file.xx when asm symlink is missing
    kbuild: in the section mismatch check try harder to find symbols
    kbuild: fix section mismatch check for unwind on IA64
    kbuild: kill false positives from section mismatch warnings for powerpc
    kbuild: kill trailing whitespace in modpost & friends
    kbuild: small update of allnoconfig description
    kbuild: make namespace.pl CROSS_COMPILE happy
    ...

    Trivial conflict in arch/ppc/boot/Makefile manually fixed up

    Linus Torvalds
     

07 Mar, 2006

1 commit


03 Mar, 2006

1 commit


19 Feb, 2006

1 commit


09 Jan, 2006

1 commit


05 Jan, 2006

1 commit

  • Here's the patch for modalias support for input classes. It uses
    comma-separated numbers, and doesn't describe all the potential keys (no
    module currently cares, and that would make the strings huge). The
    changes to input.h are to move the definitions needed by file2alias
    outside __KERNEL__. I chose not to move those definitions to
    mod_devicetable.h, because there are so many that it might break compile
    of something else in the kernel.

    The rest is fairly straightforward.

    Signed-off-by: Rusty Russell
    CC: Kay Sievers
    Signed-off-by: Greg Kroah-Hartman

    Rusty Russell
     

29 Oct, 2005

1 commit


26 Sep, 2005

1 commit


30 Aug, 2005

1 commit


07 Jul, 2005

1 commit

  • This converts the usage of struct of_match to struct of_device_id,
    similar to pci_device_id. This allows a device table to be generated,
    which can be parsed by depmod(8) to generate a map file for module
    loading.

    In order for hotplug to work with macio devices, patches to
    module-init-tools and hotplug must be applied. Those patches are
    available at:

    ftp://ftp.suse.com/pub/people/jeffm/linux/macio-hotplug/

    Signed-off-by: Jeff Mahoney
    Signed-off-by: Linus Torvalds

    Jeff Mahoney
     

28 Jun, 2005

1 commit