NetBSD-Bugs archive

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

Re: kern/41195 (NetBSD 5 RC3 can't load kernel modules)



Synopsis: NetBSD 5 RC3 can't load kernel modules

State-Changed-From-To: open->analyzed
State-Changed-By: mrg%NetBSD.org@localhost
State-Changed-When: Sun, 19 Apr 2009 02:27:47 +0000
State-Changed-Why:
i can reproduce this problem quite easily.

you can work around it by passing "-A /netbsd" (or your real kernel image)
to modload.

the difference is that /dev/ksyms has absolute symbols, and /netbsd has
data/text symbols, and ld(1) doesn't like that.

i tried applying this change from ad@ but it did not change the error:

Module Name:    src
Committed By:   ad
Date:           Fri Dec  5 21:38:10 UTC 2008

Modified Files:
        src/sys/kern: kern_ksyms.c
        src/sys/sys: ksyms.h

Log Message:
Make the fake ELF object work with gdb.

- Output a .bss section and make all the symbols relative to it, instead
  of making them absolute.
- Output a single load section, no need for two.

'gdb /dev/ksyms' still doesn't work because ksyms doesn't do mmap yet.

To generate a diff of this commit:
cvs rdiff -r1.47 -r1.48 src/sys/kern/kern_ksyms.c
cvs rdiff -r1.21 -r1.22 src/sys/sys/ksyms.h





Home | Main Index | Thread Index | Old Index