Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 26 Oct 2010 09:26:54 -0400
From:      John Baldwin <jhb@freebsd.org>
To:        freebsd-current@freebsd.org, d@delphij.net
Subject:   Re: [RFC] More meaningful information about ENOEXEC for kldload(8)
Message-ID:  <201010260926.54430.jhb@freebsd.org>
In-Reply-To: <4CC5D83E.8030505@delphij.net>
References:  <4CC5D83E.8030505@delphij.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Monday, October 25, 2010 3:19:26 pm Xin LI wrote:
> Hi,
> 
> Here is a simple patch that adds more meaning messages when kldload hits
> ENOEXEC.
> 
> Before patch:
> 
> kldload: can't load geom_eli.ko: Exec format error
> 
> After patch:
> 
> kldload: can't load geom_eli.ko: Exec format error
> kldload: Dependendent kernel module cannot be loaded from kern.module_path?
> 
> Comments?

The reason I vote know is that ENOEXEC can mean several things.  I thought you 
had a patch to catch the actual kernel error message and pass it back to 
userland.  That would be a useful feature, but this message doesn't really 
help and can point people in the wrong direction if their error is due to a 
different problem.

If you want to help the user, then I think a more useful approach would be to
tell the user to check dmesg for error messages when kldload(2) fails with 
ENOEXEC.

-- 
John Baldwin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201010260926.54430.jhb>