Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 01 Jun 2016 09:21:38 -0700
From:      John Baldwin <jhb@freebsd.org>
To:        freebsd-current@freebsd.org, Konstantin Belousov <kostikbel@gmail.com>
Subject:   Re: Unable to load freshly-built nvidia.ko @r300994.
Message-ID:  <8607493.AginXhE5HD@ralph.baldwin.cx>
In-Reply-To: <20160530185227.GZ1080@albert.catwhisker.org>
References:  <20160530123654.GW1080@albert.catwhisker.org> <20160530160342.GW38613@kib.kiev.ua> <20160530185227.GZ1080@albert.catwhisker.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Monday, May 30, 2016 11:52:27 AM David Wolfskill wrote:
> On Mon, May 30, 2016 at 07:03:42PM +0300, Konstantin Belousov wrote:
> > ...
> > > May 30 11:29:31 g1-252 root: /etc/rc: WARNING: Unable to load kernel module linux64
> > > May 30 11:29:31 g1-252 kernel: KLD linux64.ko: depends on kernel - not available or version mismatch
> > > May 30 11:29:31 g1-252 kernel: linker_load_file: Unsupported file type
> > 
> > Your kernel was built from older sources than you used to build the nvidia
> > module.  I mean, the kernel headers used for the module build where
> > updated comparing with binaries that are installed into /boot/kernel.
> 
> Hmmm...  I'm ... unlcear ... on how that could have happened.
> 
> I've copied the typescript (from the build) to
> http://www.catwhisker.org/~david/FreeBSD/head/typescript_r300994; the
> "_bw" alias (ultimately) expands to:
> 
> setenv TMPDIR /tmp && \
>  id && \
>  mount && \
>  cd /usr/src && \
>  uname -a && \
>  date && \
>  make -j16 buildworld && \
>  date && \
>  make -j16 buildkernel && \
>  date && \
>  rm -fr /boot/modules.old && \
>  cp -pr /boot/modules{,.old} && \
>  make installkernel && \
>  date && \
>  pushd /usr/ports && \
>  pushd x11/nvidia-driver && \
>  make clean ; popd ; popd && \
>  date && \
>  mergemaster -U -u 0022 -p && \
>  date && \
>  rm -fr /usr/include.old && \
>  date && \
>  mv /usr/include{,.old} && \
>  date && \
>  rm -fr /usr/share/man && \
>  date && \
>  make installworld && \
>  date && \
>  mergemaster -F -U -u 0022 -i && \
>  date && \
>  make delete-old && \
>  date && \
>  df -k

Just as a followup, this sequeunce will result in the nvidia-drier always
being stale.  You have to build the nvidia-driver after installworld for
it to use up-to-date kernel headers (installkernel only installs the kernel
and modules, it does not update the headers in /usr/include).

-- 
John Baldwin



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