Subject: Re: help with video dri/drm problems
To: Jaromir Dolecek <jdolecek@NetBSD.org>
From: Frederick Bruckman <fredb@immanent.net>
List: port-i386
Date: 10/09/2003 08:03:35
On Thu, 9 Oct 2003, Jaromir Dolecek wrote:

> Frederick Bruckman wrote:
> > by hand. It had to be force loaded, with "-f", because there seems to
> > be something wrong with the LKM versioning scheme: it complained that
> > module is <some random word>, kernel is <some other random words>,
>
> This means the LKM was compiled with different options than
> kernel, and so the LKM is not compatible with running kernel.
> Specifically, if the LKM isn't compiled with MULTIPROCESSOR,
> it will crash kernel compiled with MULTIPROCESSOR.
>
> You NEED to compile LKMs with exactly same options as kernel, such
> as:
>
> cd src/sys/lkm
> make clean
> DBG="-O2 -DMULTIPROCESSOR" make dependall
> make install

Ahh. It was indeed a multiprocessor kernel. -DMULTIPROCESSOR isn't
even defined anywhere in the kernel "Makefile", however; it's set in
opt_multiprocessor.h. So how do you know, of all the options in the
kernel config file, which options count for this purpose?

> Do NOT use forced LKM load. It WILL make the kernel crash once the
> LKM would do anything. I thought the message emitted by modload
> with -f is discouraging enough. I guess I'd need to improve it
> further :)

Well, I had to see what would happen for myself, warning or no
warning. The initial error on mismatch could stand to be clearer.

Thanks for heads ups. I will give it another try.

Frederick