public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
From: scott worley <folokai@earthlink.net>
To: gentoo-dev@cvs.gentoo.org
Subject: Re: [gentoo-dev] handling of usb in init scripts
Date: Wed Sep 19 14:56:01 2001	[thread overview]
Message-ID: <3BA90659.4090609@earthlink.net> (raw)
In-Reply-To: 20010919141125.C13715@cvs.gentoo.org

Daniel Robbins wrote:

>On Wed, Sep 19, 2001 at 01:01:45PM -0700, scott worley wrote:
>
>>Hi,
>>
>>Running rc6-r12.  I'm no init expert but it appears the localmount 
>>script assumes usbcore support is compiled, not modularized.  I rebuilt 
>>the kernel will all usb as modules so /proc/bus/usb does not exist until 
>>the usbcore module is loaded, therefore mounting of usbdevfs fails.  I 
>>can change localmount to load usbcore but in the general case the script 
>>needs to detect whether usbcore is modularized or not so no error is 
>>generated by trying to load a module which doesn't exist.  Should this 
>>be done in localmount or in the script which mounts the root filesystem r/w?
>>
>
>See if this new localmount script works for you:
>(attached)  Let me know if it does.
>
>Best Regards,
>
>
>------------------------------------------------------------------------
>
>#!/sbin/runscript
>
>depend() {
>	need checkfs
>}
>
>start() {
>	# Mount local filesystems in /etc/fstab.
>	ebegin "Mounting local filesystems"
>	mount -at nonfs,noproc,noncpfs,nosmbfs,noshm  
>	eend $? 
>	if [ -z "`grep usbdevfs /proc/filesystems`" ]
>	then
>		modprobe usbcore
>	fi
>	if [ -n "`grep usbdevfs /proc/filesystems`" ] && [ -e /proc/bus/usb ] && [ ! -e /proc/bus/usb/devices ] 
>	then
>		ebegin "Mounting USB device filesystem"
>		mount -t usbdevfs usbdevfs /proc/bus/usb
>		eend $?
>	fi
>	#swap on loopback devices, and other weirdnesses
>	ebegin "Activating (possibly) more swap"
>	/sbin/swapon -a >/dev/null 2>&1
>	eend	
>	return
>}
>
Daniel,

It loads the usb module okay but the error message I'm seeing is because 
of the usbdevfs entry in /etc/fstab.  Once I commented that fstab entry 
out then the init was flawless.

I added usb-ohci and printer to /etc/modules and the system found the 
usb printer.

Thanks,
scott worley
folokai@earthlink.net







      reply	other threads:[~2001-09-19 20:55 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-09-19 14:02 [gentoo-dev] handling of usb in init scripts scott worley
2001-09-19 14:12 ` Daniel Robbins
2001-09-19 14:56   ` scott worley [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3BA90659.4090609@earthlink.net \
    --to=folokai@earthlink.net \
    --cc=gentoo-dev@cvs.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox