From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matthias Schwarzott Date: Thu, 03 May 2007 12:13:41 +0000 Subject: Re: udev problem DVB-S/T Cards Message-Id: <200705031413.41703.zzam@gentoo.org> MIME-Version: 1 Content-Type: multipart/mixed; boundary="Boundary-00=_1HdOGC9gnnWHF0i" List-Id: References: <000301c78982$db8615e0$929241a0$@com> In-Reply-To: <000301c78982$db8615e0$929241a0$@com> To: linux-hotplug@vger.kernel.org --Boundary-00=_1HdOGC9gnnWHF0i Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline On Donnerstag, 3. Mai 2007, Razza wrote: > Bryan Kadzban wrote on 03 May 2007 12:13: > > Razza wrote: > > > I have located path_id which is in /sbin on Fedora core 5 > > > > Hmm; it should be in /lib/udev AFAIK. But maybe this doesn't matter. > > Wouldn't be the first time something is in a completely different place in > Fedora! > > > > there are some pretty long case statements in there (one I counted had > > 47 lines!), > > > Yeah, it's complicated. But I don't think we can do much about that... > > > :o) Agree - The user (me) needs to get more intelligent! > > ----------8< snip! >8---------- > > > That should be the right case, but that doesn't look like the current > > version of the script. The script from udev-110 looks like this: > > > > case "$TYPE" in > > block) > > handle_device > > echo "ID_PATH=$d" > > ;; > > scsi_tape) > > handle_device > > echo "ID_PATH=$d" > > ;; > > input) > > handle_device > > echo "ID_PATH=$d" > > ;; > > *) > > RESULT=1 > > ;; > > esac Yes, this is the case-statement I changed last time. As I did not have my changes (deleted long ago) I needed to redo it. Result is attached. The only change is duplicating one of those statementes. By the way: why isnt there just case "$TYPE" in block|scsi_tape|input) ... ;; *) esac as the code is the same in every place? The reason for no longer doing this, is that I talked to linuxtv guys, and they told me they do not support such stuff :( And well, to make it general applicable you need a good scheme to identify the cards. A. by path: like above, fails with usb devices B. by pci ids: fails with multiple identical cards, or with switching card-slots Need to be improved for cards with multiple dvb-adapters (twin-tuner and similar) C. by serial: some devices have serial numbers like usb, but not all I just switched back to blacklisting all dvb-modules, and load them in well known order. Matthias -- Matthias Schwarzott (zzam) --Boundary-00=_1HdOGC9gnnWHF0i Content-Type: text/x-diff; charset="iso-8859-1"; name="path_id-dvb.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="path_id-dvb.diff" --- /lib/udev/path_id.old 2007-05-03 14:03:39.000000000 +0200 +++ /lib/udev/path_id 2007-05-03 14:04:08.000000000 +0200 @@ -549,6 +549,10 @@ handle_device echo "ID_PATH=$d" ;; + dvb) + handle_device + echo "ID_PATH=$d" + ;; *) RESULT=1 ;; --Boundary-00=_1HdOGC9gnnWHF0i Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ --Boundary-00=_1HdOGC9gnnWHF0i Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ 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 --Boundary-00=_1HdOGC9gnnWHF0i--