linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* ieee1394 patch
@ 2003-03-20 19:04 Dan Dennedy
  2003-03-20 19:49 ` Ben Collins
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Dan Dennedy @ 2003-03-20 19:04 UTC (permalink / raw)
  To: linux-hotplug

[-- Attachment #1: Type: text/plain, Size: 732 bytes --]

I am a member of the Linux 1394 team, and I have been improving hotplug
capabilities of various ieee1394 modules. Below is my patch to the agent
script. For two different classes of video camera, some applications
require 2 modules: one for the control protocol and another for the
streaming video. Therefore, you see I removed that break. Also, I added
support for a module-specific script directory. This is especially
useful for sbp2 to invoke the popular rescan-scsi-bus.sh script, 
/etc/hotplug/ieee1394/sbp2 script:

#!/bin/bash
if [ "${ACTION}" = "add" ]; then
	. rescan-scsi-bus.sh
else
	. rescan-scsi-bus.sh -r
fi

Similarly, a dv1394 script could launch Kino on add, and a video1394
script could launch Coriander on add.


[-- Attachment #2: hotplug-ieee1394-DRD.patch --]
[-- Type: text/x-patch, Size: 1016 bytes --]

Index: etc/hotplug/ieee1394.agent
===================================================================
RCS file: /cvsroot/linux-hotplug/admin/etc/hotplug/ieee1394.agent,v
retrieving revision 1.8
diff -u -p -r1.8 ieee1394.agent
--- etc/hotplug/ieee1394.agent  18 Jan 2003 01:27:07 -0000      1.8
+++ etc/hotplug/ieee1394.agent  20 Mar 2003 17:59:02 -0000
@@ -51,7 +51,7 @@ MATCH_VERSION=0x0008
  
 #
 # stdin is "modules.ieee1394map" syntax
-# on return, ONE matching module was added to $DRIVERS
+# on return, all matching modules were added to $DRIVERS
 #
 ieee1394_map_modules ()
 {
@@ -82,7 +82,6 @@ ieee1394_map_modules ()
        fi
  
         DRIVERS="$module $DRIVERS"
-       break
     done
 }
  
@@ -103,6 +102,13 @@ add)
        mesg "... no drivers for $LABEL"
        exit 2
     fi
+
+    for MODULE in $DRIVERS
+    do
+    if [ -x $HOTPLUG_DIR/ieee1394/$MODULE ]; then
+           $HOTPLUG_DIR/ieee1394/$MODULE
+    fi
+    done
  
     if [ -x /sbin/devlabel ]; then
         /sbin/devlabel restart

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: ieee1394 patch
  2003-03-20 19:04 ieee1394 patch Dan Dennedy
@ 2003-03-20 19:49 ` Ben Collins
  2003-03-20 20:02 ` Dan Dennedy
  2003-04-18  1:56 ` David Brownell
  2 siblings, 0 replies; 4+ messages in thread
From: Ben Collins @ 2003-03-20 19:49 UTC (permalink / raw)
  To: linux-hotplug

On Thu, Mar 20, 2003 at 02:04:04PM -0500, Dan Dennedy wrote:
> I am a member of the Linux 1394 team, and I have been improving hotplug
> capabilities of various ieee1394 modules. Below is my patch to the agent
> script. For two different classes of video camera, some applications
> require 2 modules: one for the control protocol and another for the
> streaming video. Therefore, you see I removed that break. Also, I added
> support for a module-specific script directory. This is especially
> useful for sbp2 to invoke the popular rescan-scsi-bus.sh script, 
> /etc/hotplug/ieee1394/sbp2 script:
> 
> #!/bin/bash
> if [ "${ACTION}" = "add" ]; then
> 	. rescan-scsi-bus.sh
> else
> 	. rescan-scsi-bus.sh -r
> fi

Make sure this doesn't run on 2.5.x. We have scsi hotplug there.



-- 
Debian     - http://www.debian.org/
Linux 1394 - http://www.linux1394.org/
Subversion - http://subversion.tigris.org/
Deqo       - http://www.deqo.com/


-------------------------------------------------------
This SF.net email is sponsored by: Tablet PC.  
Does your code think in ink? You could win a Tablet PC. 
Get a free Tablet PC hat just for playing. What are you waiting for? 
http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en
_______________________________________________
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

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: ieee1394 patch
  2003-03-20 19:04 ieee1394 patch Dan Dennedy
  2003-03-20 19:49 ` Ben Collins
@ 2003-03-20 20:02 ` Dan Dennedy
  2003-04-18  1:56 ` David Brownell
  2 siblings, 0 replies; 4+ messages in thread
From: Dan Dennedy @ 2003-03-20 20:02 UTC (permalink / raw)
  To: linux-hotplug

On Thu, 2003-03-20 at 14:49, Ben Collins wrote:
> > 
> > #!/bin/bash
> > if [ "${ACTION}" = "add" ]; then
> > 	. rescan-scsi-bus.sh
> > else
> > 	. rescan-scsi-bus.sh -r
> > fi
> 
> Make sure this doesn't run on 2.5.x. We have scsi hotplug there.

Good point. This is mostly an example of my personal configuration. It
should be easy to add sed against uname or /proc/version to check the
kernel version for a generic script.




-------------------------------------------------------
This SF.net email is sponsored by: Tablet PC.  
Does your code think in ink? You could win a Tablet PC. 
Get a free Tablet PC hat just for playing. What are you waiting for? 
http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en
_______________________________________________
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

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: ieee1394 patch
  2003-03-20 19:04 ieee1394 patch Dan Dennedy
  2003-03-20 19:49 ` Ben Collins
  2003-03-20 20:02 ` Dan Dennedy
@ 2003-04-18  1:56 ` David Brownell
  2 siblings, 0 replies; 4+ messages in thread
From: David Brownell @ 2003-04-18  1:56 UTC (permalink / raw)
  To: linux-hotplug

Dan Dennedy wrote:
> I am a member of the Linux 1394 team, and I have been improving hotplug
> capabilities of various ieee1394 modules. Below is my patch to the agent
> script. For two different classes of video camera, some applications
> require 2 modules: one for the control protocol and another for the
> streaming video. Therefore, you see I removed that break.

Merged.  Your other patch was already in CVS; were you not
using the repository at SourceForge?

- Dave






-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
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

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2003-04-18  1:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-03-20 19:04 ieee1394 patch Dan Dennedy
2003-03-20 19:49 ` Ben Collins
2003-03-20 20:02 ` Dan Dennedy
2003-04-18  1:56 ` David Brownell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).