You are not logged in.

#1 2013-10-10 22:54:52

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 5,675

Should modules for different kernels differ?

I'm trying to build acpi_call-git from the AUR. The build seems to go rather too smoothly. I uninstalled a custom kernel (which I only have for debugging) which leaves the standard Arch and Arch LTS kernels installed. I have the headers installed for both kernels:

$ pacman -Qs linux-[lts-]*headers
local/linux-headers 3.11.4-1
    Header files and scripts for building modules for Linux kernel
local/linux-lts-headers 3.10.15-1
    Header files and scripts for building modules for Linux-lts kernel

What is confusing me is that the package seems to build identical modules for the two kernels and I am not sure whether that's right:

$ diff pkg/acpi_call-git/usr/lib/modules/extramodules-3.11-ARCH/acpi_call.ko.gz pkg/acpi_call-git/usr/lib/modules/extramodules-3.10-lts/acpi_call.ko.gz 
$ echo $?
0

Shouldn't there be a difference between the two? That is, I know that you typically need modules which match the kernel - otherwise the modules can't be loaded. So presumably if building module M for kernel K1 produces M1, and building module M for kernel K2 produces M2, then M1 cannot be identical with M2.

Is there a problem here or am I just horribly confused?


How To Ask Questions The Smart Way | Help Vampires

Arch Linux | x86_64 | GPT | EFI boot | grub2 | systemd | LVM2 on LUKS
Lenovo x121e | Intel(R) Core(TM) i3-2367M CPU @ 1.40GHz GenuineIntel | Intel Centrino Wireless-N 1000 | US keyboard with Euro | 320G 7200 RPM Seagate HDD

Offline

#2 2013-10-11 12:01:20

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 4,416

Re: Should modules for different kernels differ?

If the kernel functions (especially the specifications) used by acpi_call haven't changed, then the module could indeed be the same for both kernels.

You'd have to check the kernel commits for acpi related changes to be sure.


Booting with apg Openrc, NOT systemd.
Automounting : not needed, i prefer pmount
Aur helpers : makepkg + my own local repo === rarely need them

Offline

#3 2013-10-11 22:38:15

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 5,675

Re: Should modules for different kernels differ?

What makes me suspicious is that it produces exactly the same file for a third kernel with no headers installed. I don't think it is designed to handle the presence of multiple kernels at all.


How To Ask Questions The Smart Way | Help Vampires

Arch Linux | x86_64 | GPT | EFI boot | grub2 | systemd | LVM2 on LUKS
Lenovo x121e | Intel(R) Core(TM) i3-2367M CPU @ 1.40GHz GenuineIntel | Intel Centrino Wireless-N 1000 | US keyboard with Euro | 320G 7200 RPM Seagate HDD

Offline

Board footer

Powered by FluxBB