[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#544305: load of some acpi.ko leads to panic on GNU/kFreeBSD



Package: grub2
User: debian-bsd@lists.debian.org
Usertags: kfreebsd
X-Debbugs-CC: debian-bsd@lists.debian.org, grub-devel@gnu.org


Hello,

we have some problems with grub2 and loading acpi.ko for FreeBSD kernel.
With some acpi.ko the kernel panics. The same kernel without acpi.ko
boots fine. See also thread started by
http://lists.debian.org/debian-bsd/2009/08/msg00147.html

It is still unclear what the real reason is,
so far only acpi enable boots are affected.
It looks like the problem lies in interaction
between gnu linker and grub bootloader and FreeBSD kernel.

Maybe only GRUB 2 based installation are affected,
the kfreebsd-loader loads acpi.ko from 7.2-5 fine.

There are 3 different version of acpi.ko,
compiled by different binutils and/or different linking parameters.

a) acpi_725_fail.ko
b) acpi_b20090805_fail.ko
c) acpi_b20090723_works.ko

The only difference between b) and c) is .comment section.
After "objcopy --remove-section=.comment" it loads also fine.

The interesting might be parts of "readelf -l -S",
the differences are:

Program Headers:
a)
  Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
  LOAD           0x000000 0x00000000 0x00000000 0x54248 0x54248 R E 0x1000
  LOAD           0x054248 0x00055248 0x00055248 0x02414 0x03c84 RW  0x1000
  DYNAMIC        0x054248 0x00055248 0x00055248 0x00078 0x00078 RW  0x4
  GNU_STACK      0x000000 0x00000000 0x00000000 0x00000 0x00000 RWE 0x4

b), c)
  Type           Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
  LOAD           0x000000 0x00000000 0x00000000 0x54008 0x54008 R E 0x1000
  LOAD           0x055000 0x00055000 0x00055000 0x0241c 0x03c8c RW  0x1000
  DYNAMIC        0x055000 0x00055000 0x00055000 0x00078 0x00078 RW  0x4
  GNU_STACK      0x000000 0x00000000 0x00000000 0x00000 0x00000 RWE 0x4

Length and attributes of .comment section

a) [15] .comment          PROGBITS        00000000 05665c 000cd8 01  MS  0   0  1
b) [15] .comment          PROGBITS        00000000 05741c 000cd8 01  MS  0   0  1
c) [15] .comment          PROGBITS        00000000 05741c 001cef 00      0   0  1

I will try to attach all acpi.ko to the debian BTS later.

Petr



Reply to: