Main > Linux

current status of gentoo linux / advmame

<< < (6/16) > >>

Major Rock Hardy:
K, I ignored them and went on... and I got this when I tried to insmod:

persephone svgalib-1.9.19 # insmod /lib/modules/2.6.14-gentoo-r2/kernel/misc/svgalib_helper.ko
insmod: error inserting '/lib/modules/2.6.14-gentoo-r2/kernel/misc/svgalib_helper.ko': -1 Unknown symbol in module


any thoughts?  should I be doing this a different way for Gentoo?

Thanks again,
Rock

Major Rock Hardy:
desmatic suggests:

If the svgalib_helper module won't load
1. you compiled svgalib with a different compiler than the one used to compile your kernel
2. you are trying to load the wrong version of the module. 2.6.x modules end in .ko and 2.4.x modules in .o Both modules can be found in the kernel/svgalib_helper directory. The SVGAlib make install by default places these modules in /lib/modules/`uname -r`/kernel/misc directory.

as far as I can tell, NEITHER apply to me... FYI:

me@persephone /usr/src/svgalib-1.9.19 $ gcc --version; cat /proc/version
gcc (GCC) 3.3.5-20050130 (Gentoo 3.3.5.20050130-r1, ssp-3.3.5.20050130-1, pie-8.7.7.1)
Copyright (C) 2003 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Linux version 2.6.14-gentoo-r2 (root@persephone) (gcc version 3.3.5-20050130 (Gentoo 3.3.5.20050130-r1, ssp-3.3.5.20050130-1, pie-8.7.7.1)) #10 PREEMPT Sat Dec 3 20:16:04 MST 2005

...
and see above for proof that I tried to load the .ko instead of the .o

 :-\

Rock

elvis:
Oooh that rings a bell.  I got an "unknown symbol" error a while back from memory.

Check:

a) If you *need* the patches for your kernel (I believe one of the patches does not need issuing after 2.6.8 because something was fixed in the kernel)

b) That your kernel revision is supported (you might need to downgrade your kernel).

Check the readme's that go with the patches, and read them all start to finish whether they seem obvious or not.

Bugger... there was something else I had to do to get rid of that "unknown symbol" error but I can't remember what!  Time to google...

[edit] a voice in my head is telling me it was something to do with a udev/devfs problem... still googling...

[edit2] run:

dmesg | grep -i 'svga'

And see what get's spat out.  If you get an error about it not being able to make a symlink in devfs or something similar, read the following thread and see if it helps:
http://forums.gentoo.org/viewtopic-t-331838-highlight-svgalibhelper.html

Major Rock Hardy:
Man I'm getting into the nitty-gritty...

I ran your
dmesg | grep -i svga
and got:
svgalib_helper: Unknown symbol pci_find_class
svgalib_helper: Unknown symbol io_remap_page_range

so due to this thread on the gentoo forums (http://forums.gentoo.org/viewtopic.php?t=216985) it looks as if the kernel? function "pci_find_class" was at some point (and perhaps only in gentoo kernels?) changed to "pci_get_class".

so from the svgalib-1.9.19 directory, I ran
grep -r pci_find_class *
 and it was only in one source file:
kernel/svgalib_helper/main.c:                                   pci_find_class(PCI_CLASS_DISPLAY_VGA<<8,dev)) &&

so I just went into this file (kernel/svgalib_helper/main.c) and changed "pci_find_class" to "pci_get_class".

Then from the svgalib-1.9.19 directory, I ran
make clean
make install
make demoprogs
cp -f kernel/svgalib_helper/svgalib_helper.ko /lib/modules/2.6.14-gentoo-r2/kernel/misc/svgalib_helper.ko
insmod /lib/modules/2.6.14-gentoo-r2/kernel/misc/svgalib_helper.ko


still got:
insmod: error inserting '/lib/modules/2.6.14-gentoo-r2/kernel/misc/svgalib_helper.ko': -1 Unknown symbol in module

however, upon running
dmesg | grep -i svga

now it just says:
svgalib_helper: Unknown symbol io_remap_page_range

so I got one of them, still working on the other... stay tuned.

Thanks again elvis,
Rock


Major Rock Hardy:
Oh boy...

to get the other message (svgalib_helper: Unknown symbol io_remap_page_range) to go away it was a bit more involved... I finally found a french google groups posting (http://groups.google.fr/group/svgalib/browse_thread/thread/baea20cf230bbbf8/2d3796c629b5890c?hl=fr)

So I went to the svgalib-1.9.19 directory and added a few lines (MAKE A BACKUP COPY FIRST) to kernel/svgalib_helper/kernel26compat.h (relative path) to make this:


--- Code: ---#else /* Kernel 2.6 */

#define NO_TASK

# ifndef KERNEL_2_6
#  define KERNEL_2_6
# endif

# define my_io_remap_page_range(vma, start, ofs, len, prot) \
                io_remap_page_range(vma,start,ofs,len,prot)

--- End code ---

look like this:


--- Code: ---#else /* Kernel 2.6 */

#define NO_TASK

# ifndef KERNEL_2_6
#  define KERNEL_2_6
# endif

// majorrockhardy - added this vvvvvv
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,14)
# define io_remap_page_range(vma, vaddr, paddr, size, prot)            \
                remap_pfn_range(vma, vaddr, (paddr) >> PAGE_SHIFT, size, prot)
#endif
// majorrockhardy - added this ^^^^^^

# define my_io_remap_page_range(vma, start, ofs, len, prot) \
                io_remap_page_range(vma,start,ofs,len,prot)

--- End code ---


Then from the svgalib-1.9.19 directory, I ran
make clean
make install
make demoprogs
cp -f kernel/svgalib_helper/svgalib_helper.ko /lib/modules/2.6.14-gentoo-r2/kernel/misc/svgalib_helper.ko

so here's the insmod result:

me@persephone /usr/src/svgalib-1.9.19 $ insmod /lib/modules/2.6.14-gentoo-r2/kernel/misc/svgalib_helper.ko
me@persephone /usr/src/svgalib-1.9.19 $ dmesg -c | grep -i svga
svgalib_helper: Initializing, version 1.9.19
svgalib_helper: device1: vendor:1002 id:5159

no more errors!

success (maybe)... stay tuned...


Rock

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version