Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Jun 2018 17:05:25 +0200
From:      Michael Tuexen <tuexen@freebsd.org>
To:        Alexey Dokuchaev <danfe@FreeBSD.org>
Cc:        FreeBSD PowerPC ML <freebsd-ppc@freebsd.org>
Subject:   Re: Loading modules from /boot/loader.conf
Message-ID:  <FD99A302-366A-4C15-9CB2-79DACA4D16FA@freebsd.org>
In-Reply-To: <20180626053314.GA30244@FreeBSD.org>
References:  <6DB7ABD4-8C04-46B3-8C07-FC591FC16F71@freebsd.org> <20180626053314.GA30244@FreeBSD.org>

index | next in thread | previous in thread | raw e-mail

> On 26. Jun 2018, at 07:33, Alexey Dokuchaev <danfe@FreeBSD.org> wrote:
> 
> On Mon, Jun 25, 2018 at 07:17:42PM +0200, Michael Tuexen wrote:
>> I'm running FreeBSD head of today on a G4 MacMini. I'm trying to
>> load a kernel module using /boot/loader.conf by having the line
>> 
>> tcp_rack_load="YES" in /boot/loader.conf.
>> 
>> However, this doesn't work and results in [module 'kernel' exists but
>> with wrong version].  I have no problems when running "kldload tcp_rack"
>> after the system completely booted.  Then the module loads without any
>> problems.
> 
> I don't know what's causing it and cannot reproduce it right now (but then
> again, I'm still running fairly old r302710 -CURRENT on my G4), but I've
> heard about this very problem from another FreeBSD-on-G4 user.
I did some testing...

If I'm loading the kernel in the loader and then run lsmod -v I only see a single module
with name 'kernel' and version 1. This is wrong, I guess.

When doing the same on powerpc64, i386, and amd64, I see multiple modules
listen and also the kernel with a number like 1200069.

It comes from calling file_addmodule() at
https://svnweb.freebsd.org/base/head/stand/common/load_elf.c?view=markup#l1102

I guess this is not the expected code path, or am I wrong? I would expect that
https://svnweb.freebsd.org/base/head/stand/common/load_elf.c?view=markup#l1094
should have been used.

Any ideas or suggestions?

Best regards
Michael
> 
> ./danfe



help

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?FD99A302-366A-4C15-9CB2-79DACA4D16FA>