Results 1 to 2 of 2

Thread: OpenSuse 11.1 kernel module recompilation

  1. #1

    Default OpenSuse 11.1 kernel module recompilation


    I have a serious problem when recompiling
    the USB drivers after changing one of them.
    I've added EXPORT_SYMBOL(usb_kick_khubd)
    to HUB.C within drivers/usb/core.

    Then I did the following.
    - cd /usr/src/linux
    - cp /usr/src/linux-obj/$arch/$flavour/.config .
    - cp /usr/src/linux-obj/$arch/$flavour/Module.symvers .
    - make prepare
    - make modules_prepare
    - cd drivers/usb
    - make -C /lib/modules/$(uname -r)/build M=$(pwd)
    - make -C /lib/modules/$(uname -r)/build M=$(pwd) modules_install

    Everything went fine, drivers are compiled
    and installed into the PAE/extra folder
    (I'm using the kernel).

    HOWEVER after boot I did a:

    modinfo usbcore (as hub.c is within usbcore)

    and it displayed that the .KO is loaded
    NOT from the /extra folder but from the
    regular kernel/drivers/usb/core.

    So I have owerwritten the .KO there with the
    fresh one. After yet another reboot
    I did a:

    cat /proc/kallsyms | grep usb_kick_khubd

    and it returned only a "t" entry with
    usb_kick_khubd, but NO corresponding __ksymtab, __kstrtab entries.

    Naturally I cannot load any other .KOs
    using "usb_kick_khubd" as I get "unknown symbol
    in module" for sure.

    I have tried manually updating all the Module.symvers files:

    - lib/modules/$(uname -r)/modules.symbols
    - lib/modules/$(uname -r)/Module.symvers
    - lib/modules/$(uname -r)/build/Module.symvers

    But obviously no luck, I cannot change the
    usb_kick_khubd to global.

    Please help me. What am I doing wrong?

    p.s. Also would DIE for an official, proper,
    up-to-date description of how to recompile
    one, single kernel module without complete kernel recompilation.

  2. #2

    Default Re: OpenSuse 11.1 kernel module recompilation

    Khm. Sorry. Lame me. Forgot that
    usbcore is within initrd, thus I had to
    do a "mkinitrd -s 1024x768" after compilation
    so that the new usbcore.ko INDEED GETS into
    the initrd and not the old one sits there.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts