* embedded hotplugging
@ 2005-03-15 13:30 andreas.walden
2005-03-15 14:44 ` Kay Sievers
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: andreas.walden @ 2005-03-15 13:30 UTC (permalink / raw)
To: linux-hotplug
Hi,
I'm working on an CSB337 Cogent Board with ATM AT91RM9200 and Linux
2.6.11-rc5. I have installed hotplug-ng an I want to start a Programm when
plugging in USB device on my Board...
I' ve put the Link 10-usb2serial.hotplug in /etc/hotplug.d/input/ but the
ps output says that it is running twice. So what do I make wrong???
[root@CSB337 log]# ps
PID Uid VmSize Stat Command
1 root 156 S init
2 root SWN [ksoftirqd/0]
3 root SW< [events/0]
4 root SW< [khelper]
9 root SW< [kthread]
14 root SW< [kblockd/0]
22 root SW [khubd]
55 root SW [pdflush]
56 root SW [pdflush]
58 root SW< [aio/0]
57 root SW [kswapd0]
130 root SW [kseriod]
154 root SW [mtdblockd]
170 root SW< [rpciod/0]
192 root 628 S /sbin/inetd
214 root 1172 S -bash
215 root 160 D /sbin/syslogd -n -m 0
216 root 124 S /sbin/klogd -n
330 root 36 S < /sbin/hotplug input
331 root 280 S < /etc/hotplug.d/input/10-usb2serial.hotplug input
332 root 36 S < /sbin/hotplug input
333 root 280 S < /etc/hotplug.d/input/10-usb2serial.hotplug input
334 root 152 R ps
Mit freundlichen Grüßen / Kind regards
Andreas Walden
PHILIPS MEDIZIN
SYSTEME
BÖBLINGEN GMBH
Andreas Walden
Phone: +49 (0)7031 / 463-2014 Gebäude 5
Fax: +49 (0)7031 / 463-2202 Hewlett-Packard-Strasse 2
Email: Andreas.Walden@philips.com D-71034 Boeblingen
Sametime enabled
Geschäftsführer: Sitz der Gesellschaft:
Michael Dreher Böblingen Registergericht
(Sprecher), Böblingen
Jochen M. Reg.-Nr. HRB 5187
Franke, Dr.
Werner Haas
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_ide95&alloc_id\x14396&opÌk
_______________________________________________
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] 5+ messages in thread
* Re: embedded hotplugging
2005-03-15 13:30 embedded hotplugging andreas.walden
@ 2005-03-15 14:44 ` Kay Sievers
2005-03-15 15:35 ` andreas.walden
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Kay Sievers @ 2005-03-15 14:44 UTC (permalink / raw)
To: linux-hotplug
[-- Attachment #1: Type: text/plain, Size: 643 bytes --]
On Tue, 2005-03-15 at 14:30 +0100, andreas.walden@philips.com wrote:
> Hi,
>
> I'm working on an CSB337 Cogent Board with ATM AT91RM9200 and Linux
> 2.6.11-rc5. I have installed hotplug-ng an I want to start a Programm when
> plugging in USB device on my Board...
>
> I' ve put the Link 10-usb2serial.hotplug in /etc/hotplug.d/input/ but the
> ps output says that it is running twice. So what do I make wrong???
You may record the events with something like the attached script
by placing it into:
/etc/hotplug.d/default/
and look for what devices the events are. Your script will need to check
if it is invoked for the right one.
Kay
[-- Attachment #2: 00-log.hotplug --]
[-- Type: application/x-shellscript, Size: 140 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: embedded hotplugging
2005-03-15 13:30 embedded hotplugging andreas.walden
2005-03-15 14:44 ` Kay Sievers
@ 2005-03-15 15:35 ` andreas.walden
2005-03-15 15:48 ` Kay Sievers
2005-03-21 22:27 ` Andreas Walden
3 siblings, 0 replies; 5+ messages in thread
From: andreas.walden @ 2005-03-15 15:35 UTC (permalink / raw)
To: linux-hotplug
[-- Attachment #1: Type: text/plain, Size: 2848 bytes --]
Hello Kay,
I've installed the script in the mentioned directory but I think it doesn't
work: Here is the /var/log/messages file with the log from hotplug.
thx, Andi
(See attached file: messages3.txt)
|---------+---------------------------->
| | |
| | |
| | |
| | |
| | |
| | Kay Sievers |
| | <kay.sievers@vrfy.org> |
| | |
| | 15.03.2005 15:44 |
|---------+---------------------------->
>---------------------------------------------------------------------------------------------------------------------------------------------|
| |
| To: Andreas Walden/BBL/MS/PHILIPS@PHILIPS |
| cc: linux-hotplug-devel@lists.sourceforge.net |
| Subject: Re: embedded hotplugging |
| |
| Classification: Unclassified |
| |
| |
>---------------------------------------------------------------------------------------------------------------------------------------------|
On Tue, 2005-03-15 at 14:30 +0100, andreas.walden@philips.com wrote:
> Hi,
>
> I'm working on an CSB337 Cogent Board with ATM AT91RM9200 and Linux
> 2.6.11-rc5. I have installed hotplug-ng an I want to start a Programm
when
> plugging in USB device on my Board...
>
> I' ve put the Link 10-usb2serial.hotplug in /etc/hotplug.d/input/ but the
> ps output says that it is running twice. So what do I make wrong???
You may record the events with something like the attached script
by placing it into:
/etc/hotplug.d/default/
and look for what devices the events are. Your script will need to check
if it is invoked for the right one.
Kay
[attachment "00-log.hotplug" deleted by Andreas Walden/BBL/MS/PHILIPS]
[-- Attachment #2: messages3.txt --]
[-- Type: text/plain, Size: 6835 bytes --]
Jan 1 02:35:02 CSB337 user.info kernel: usb 1-1: new low speed USB device using at91rm9200-ohci and address 25
Jan 1 02:35:02 CSB337 user.debug kernel: DEV: registering device: ID = '1-1'
Jan 1 02:35:02 CSB337 user.debug kernel: hotplug[680]: main: dirname: /etc/hotplug.d/usb
Jan 1 02:35:02 CSB337 user.debug kernel: hotplug[680]: call_foreach_file: open directory '/etc/hotplug.d/usb'
Jan 1 02:35:02 CSB337 user.debug kernel: hotplug[680]: call_foreach_file: put file '/etc/hotplug.d/usb/module_usb.hotplug' in list
Jan 1 02:35:02 CSB337 user.debug kernel: hotplug[680]: run_program: running /etc/hotplug.d/usb/module_usb.hotplug
Jan 1 02:35:02 CSB337 user.debug kernel: module_usb[681]: main: subsystem = usb
Jan 1 02:35:02 CSB337 user.debug kernel: module_usb[681]: main: action = 'add'
Jan 1 02:35:02 CSB337 user.debug kernel: module_usb[681]: add: module_form.c started ...
Jan 1 02:35:02 CSB337 user.debug kernel: module_usb[681]: add: PRODUCT='(null)', TYPE = '(null)'
Jan 1 02:35:02 CSB337 user.debug kernel: module_usb[681]: add: missing an environment variable, aborting.
Jan 1 02:35:02 CSB337 user.debug kernel: hotplug[680]: call_foreach_file: open directory '/etc/hotplug.d/default'
Jan 1 02:35:02 CSB337 user.debug kernel: hotplug[680]: call_foreach_file: put file '/etc/hotplug.d/default/00-log.hotplug' in list
Jan 1 02:35:02 CSB337 user.debug kernel: hotplug[680]: run_program: running /etc/hotplug.d/default/00-log.hotplug
Jan 1 02:35:02 CSB337 user.debug kernel: hotplug[680]: run_program: exec of child failed
Jan 1 02:35:02 CSB337 user.debug kernel: bus usb: add device 1-1
Jan 1 02:35:02 CSB337 user.debug kernel: bound device '1-1' to driver 'usb'
Jan 1 02:35:02 CSB337 user.debug kernel: DEV: registering device: ID = '1-1:1.0'
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[683]: main: dirname: /etc/hotplug.d/usb
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[683]: call_foreach_file: open directory '/etc/hotplug.d/usb'
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[683]: call_foreach_file: put file '/etc/hotplug.d/usb/module_usb.hotplug' in list
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[683]: run_program: running /etc/hotplug.d/usb/module_usb.hotplug
Jan 1 02:35:03 CSB337 user.debug kernel: bus usb: add device 1-1:1.0
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: main: subsystem = usb
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: main: action = 'add'
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: add: module_form.c started ...
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: add: PRODUCT='46d/c03d/2000', TYPE = '0/0/0'
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = 46d
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value1 = 1133
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = c03d
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value2 = 49213
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = 2000
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value3 = 8192
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = 0
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value1 = 0
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = 0
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value2 = 0
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = 0
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value3 = 0
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = 3
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value1 = 3
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = 1
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value2 = 1
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: buffer = 2
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: split_3values: value3 = 2
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: load_module: modprobe startet...
Jan 1 02:35:03 CSB337 user.debug kernel: module_usb[684]: load_module: loading module usb:v046DpC03Ddl2000dh2000dc00dsc00dp00ic03isc01ip02
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[683]: call_foreach_file: open directory '/etc/hotplug.d/default'
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[683]: call_foreach_file: put file '/etc/hotplug.d/default/00-log.hotplug' in list
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[683]: run_program: running /etc/hotplug.d/default/00-log.hotplug
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[683]: run_program: exec of child failed
Jan 1 02:35:03 CSB337 user.debug kernel: CLASS: registering class device: ID = 'mouse0'
Jan 1 02:35:03 CSB337 user.debug kernel: class_hotplug - name = mouse0
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[687]: main: dirname: /etc/hotplug.d/input
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[687]: call_foreach_file: open directory '/etc/hotplug.d/input'
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[687]: call_foreach_file: unable to open '/etc/hotplug.d/input'
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[687]: call_foreach_file: open directory '/etc/hotplug.d/default'
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[687]: call_foreach_file: put file '/etc/hotplug.d/default/00-log.hotplug' in list
Jan 1 02:35:03 CSB337 user.debug kernel: hotplug[687]: run_program: running /etc/hotplug.d/default/00-log.hotplug
Jan 1 02:35:04 CSB337 user.debug kernel: hotplug[687]: run_program: exec of child failed
Jan 1 02:35:04 CSB337 user.debug kernel: hotplug[689]: main: dirname: /etc/hotplug.d/input
Jan 1 02:35:04 CSB337 user.debug kernel: hotplug[689]: call_foreach_file: open directory '/etc/hotplug.d/input'
Jan 1 02:35:04 CSB337 user.debug kernel: hotplug[689]: call_foreach_file: unable to open '/etc/hotplug.d/input'
Jan 1 02:35:04 CSB337 user.debug kernel: hotplug[689]: call_foreach_file: open directory '/etc/hotplug.d/default'
Jan 1 02:35:04 CSB337 user.info kernel: input: Logitech USB-PS/2 Optical Mouse on usb-at91rm9200-ohci-1
Jan 1 02:35:04 CSB337 user.debug kernel: bound device '1-1:1.0' to driver 'usbmouse'
Jan 1 02:35:04 CSB337 user.debug kernel: hotplug[689]: call_foreach_file: put file '/etc/hotplug.d/default/00-log.hotplug' in list
Jan 1 02:35:04 CSB337 user.debug kernel: hotplug[689]: run_program: running /etc/hotplug.d/default/00-log.hotplug
Jan 1 02:35:04 CSB337 user.debug kernel: hotplug[689]: run_program: exec of child failed
[-- Attachment #3: 00-log.hotplug --]
[-- Type: application/octet-stream, Size: 148 bytes --]
#!/bin/sh
echo -e "--------$SEQNUM--------\n"\
`date +%s` $ACTION $DEVPATH"\n"\
`env`\
"\n--------$SEQNUM--------\n" >> /tmp/hotplug_d.log
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: embedded hotplugging
2005-03-15 13:30 embedded hotplugging andreas.walden
2005-03-15 14:44 ` Kay Sievers
2005-03-15 15:35 ` andreas.walden
@ 2005-03-15 15:48 ` Kay Sievers
2005-03-21 22:27 ` Andreas Walden
3 siblings, 0 replies; 5+ messages in thread
From: Kay Sievers @ 2005-03-15 15:48 UTC (permalink / raw)
To: linux-hotplug
On Tue, 2005-03-15 at 16:35 +0100, andreas.walden@philips.com wrote:
> Hello Kay,
>
>
> I've installed the script in the mentioned directory but I think it doesn't
> work: Here is the /var/log/messages file with the log from hotplug.
Is it executable? Try invoking it from the command line...
Kay
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_ide95&alloc_id\x14396&op=click
_______________________________________________
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] 5+ messages in thread
* embedded hotplugging
2005-03-15 13:30 embedded hotplugging andreas.walden
` (2 preceding siblings ...)
2005-03-15 15:48 ` Kay Sievers
@ 2005-03-21 22:27 ` Andreas Walden
3 siblings, 0 replies; 5+ messages in thread
From: Andreas Walden @ 2005-03-21 22:27 UTC (permalink / raw)
To: linux-hotplug
Hello,
I've got a problem with my AT91RM9200, Linux 2.6.11 and hotplug. In
/etc/hotplug/input there's a script which invokes a self written
c-program with the parameters $ACTION $DEVPATH, $PHYSDEVDRIVER... Only
when Action="add", DEVPATH="/class/dev/mousex" and
PHYSDEVDRIVER="usbmouse" are set the script invokes the programm. But in
fact the program doesn't work properly... Starting the script manually,
the program works properly emulating an PS/2 Mouse but while invoking
the script by hotplug this doesn't work. The program starts but the
emulation fails. Is it possible, that the script is invoked to quick???
Sleep for a few seconds in script doesn't fix the problem...
regards,
Andreas
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_ide95&alloc_id\x14396&op=click
_______________________________________________
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] 5+ messages in thread
end of thread, other threads:[~2005-03-21 22:27 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-15 13:30 embedded hotplugging andreas.walden
2005-03-15 14:44 ` Kay Sievers
2005-03-15 15:35 ` andreas.walden
2005-03-15 15:48 ` Kay Sievers
2005-03-21 22:27 ` Andreas Walden
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).