Trying to compile a Linux kernel with USB debugging enabled. Again. See 2004-07-04 Software.
Added this to _etc_apt/sources.list
deb-src ftp://ftp.de.debian.org/debian/ unstable main
Downloaded, compiled and installed a kernel:
apt-get update cd /usr/local/src apt-get source source kernel-tree-2.6.8 make menuconfig make make install make modules_install
And I had to edit drivers/net/Makefile to comment out the following line:
obj-$(CONFIG_TIGON3) += tg3.o
The rest seemed without problems.
I then added the following to _boot_grub/menu.lst:
title Custom Linux 2.6.8 root (hd1,2) kernel /boot/vmlinuz-2.6.8 root=/dev/hdb3
When I use this entry, same ol’ error:
VFS: Cannot open root device "hdb3" or unknown-block (0,0) Please append correct "root=" boot option Kernel panic:VFS: Unable to mount root fs on unknown-block (0,0)
I checked menuconfig again, and yes, ext3 is compiled as a module. Perhaps that is the problem? Retrying... (make, make install, make modules_install)
It persists! >-{
Double checking. Here’s the output of `mount` for a running kernel. Clearly `/dev/hdb3` is root.
/dev/hdb3 on / type ext3 (rw,errors=remount-ro) proc on /proc type proc (rw) sysfs on /sys type sysfs (rw) devpts on /dev/pts type devpts (rw,gid=5,mode=620) tmpfs on /dev/shm type tmpfs (rw) /dev/hda1 on /mnt/dos type vfat (rw,noexec,nosuid,nodev) /dev/hda3 on /mnt/dump3 type ext3 (rw) /dev/hda5 on /mnt/opt type ext3 (rw) /dev/hda6 on /mnt/src type ext3 (rw) /dev/hda7 on /mnt/var type ext3 (rw) /dev/hda8 on /home type ext3 (rw) /dev/hda9 on /usr/local type ext3 (rw) /dev/hdc1 on /mnt/pics type ext3 (rw) /dev/hdc2 on /mnt/music type ext3 (rw) /dev/hdc3 on /mnt/sounds type ext3 (rw) /dev/hdc5 on /mnt/kino type ext3 (rw) /dev/hdc6 on /mnt/cdimage type ext3 (rw) /dev/hdc7 on /mnt/movies type ext3 (rw) usbfs on /proc/bus/usb type usbfs (rw)
Matthai on #debian had a similar problem. He asked:
Can I turn devfs off using kernel parameter? I’m upgrading from 2.4 to 2.6 and it won’t boot since it can’t find root on _dev_hda3 because it uses devfs, yet I don’t know how to get it working using devfs.
He says that devfs gets initialized but drives don’t. Ok, good point.
caphuso on #debian suggest I try to reuse an old config that worked. Take the .config of the working kernel, “make oldconfig” it, turn on USB debugging, then compile. Hm.
cp /boot/config-2.6.8-1-k7 \ /usr/local/src/kernel-source-2.6.8-2.6.8/.config make oldconfig (give default answers) make menuconfig (enable USB debugging) make
The output showed that all it did was compile ext3 as a module again. So it is not in the config. I will try initrd next. make-kpkg should do it for me...
make-kpkg --initrd /usr/local/src/kernel-source-2.6.8-2.6.8# make-kpkg --initrd test ! -f stamp-debian && test ! -f debian/official && \ rm -rf ./debian && mkdir ./debian make: [stamp-debian] Error 1 (ignored) test ! -f stamp-debian && \ ( test ! -f debian/official || test ! -f debian/control) && \ sed -e 's/=V/2.6.8/g' -e 's/=D/2.6.8-2/g' \ -e 's/=A/i386/g' -e 's/=SA//g' \ -e 's/=L/lilo (>= 19.1) | grub, /g' -e 's/=I/initrd-tools (>= 0.1.48), /g' \ -e 's/=CV/2.6/g' \ -e 's/=M/Unknown Kernel Package Maintainer <unknown@unconfigured.in.etc.kernel-pkg.conf>/g' \ /usr/share/kernel-package/Control> debian/control make: [stamp-debian] Error 1 (ignored) test ! -f stamp-debian && test ! -f debian/official && \ sed -e 's/=V/2.6.8/g' -e 's/=D/2.6.8-2/g' \ -e 's/=A/i386/g' -e 's/=M/Unknown Kernel Package Maintainer <unknown@unconfigured.in.etc.kernel-pkg.conf>/g' \ /usr/share/kernel-package/changelog > debian/changelog make: [stamp-debian] Error 1 (ignored) test ! -f debian/rules && \ install -p -m 755 /usr/share/kernel-package/rules debian/rules make: [stamp-debian] Error 1 (ignored) echo done > stamp-debian /usr/bin/make -f debian/rules INCLUDE_KERNEL_MAKEFILE=yes conf_vars make[1]: Entering directory `/mnt/src/kernel-source-2.6.8-2.6.8' make[1]: *** No rule to make target `conf_vars'. Stop. make[1]: Leaving directory `/mnt/src/kernel-source-2.6.8-2.6.8' make: *** [conf.vars] Error 2
Grrrrr! >-{
See 2004-08-30 Software for the continuation. I think what I was missing was a `make-kpkg --config menuconfig`.
#Software