From mboxrd@z Thu Jan 1 00:00:00 1970 From: Olaf Hering Date: Tue, 10 Jun 2003 10:51:09 +0000 Subject: Re: [PATCH] syntax error in load_drivers, LOADED unset Message-Id: List-Id: References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: linux-hotplug@vger.kernel.org On Mon, Jun 09, David Brownell wrote: > Olaf Hering wrote: > >This avoids the ' if [ =3D false ] ' syntax error: > >I have seen it also in the debian patch. >=20 > Not needed with that other fix to initialize LOADED at the > top of the loop ... I believe the current code is buggy. We set LOADED to false 'lsmod | grep -q "^$MODULE "' will trigger the blacklist check and the modprobe. If the driver is already loaded because another device triggered a load earlier, or because it was loaded for other reasons, then LOADED will remain 'false'. LOADED will eventually become true if a usermode helper $TYPE/$MODULE exists. If none exists, this message is triggered, which is misleading: mesg "missing kernel or user mode driver $MODULE " Was something like this the intention? ... for MODULE in $DRIVERS do =20 # maybe driver modules need loading LOADED=FAlse lsmod | grep -q "^$MODULE " && LOADED=3Dtrue if [ $LOADED =3D false ] ; then ... Gruss Olaf --=20 USB is for mice, FireWire is for men! ------------------------------------------------------- This SF.net email is sponsored by: Etnus, makers of TotalView, The best thread debugger on the planet. Designed with thread debugging features you've never dreamed of, try TotalView 6 free at www.etnus.com. _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel