* Waiting complete insertion of usb device
@ 2009-09-15 9:13 Anthony Viallard
2009-09-15 15:28 ` Greg KH
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Anthony Viallard @ 2009-09-15 9:13 UTC (permalink / raw)
To: linux-hotplug
Hello list,
I'm working on a 3G USB dongle which offer tty to communicate with him.
I need to start a service when this dongle is plugged to my system. This
service uses tty (there are 4 tty (diag, cmd, data and for voice). So, i
need to waiting the complete insertion of the USB dongle before
launching it.
For now, i'm waiting the last tty (ttyUSB3) event, sleep 1 second and
launch the service. But i think my solution is pretty crap.
Is there a better way to do this ?
(I'm working with old architecture of hotplug: /bin/hotplug script which
launch /etc/hotplug.d/${SUBSYSTEM}/ scripts...)
Anthony.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Waiting complete insertion of usb device
2009-09-15 9:13 Waiting complete insertion of usb device Anthony Viallard
@ 2009-09-15 15:28 ` Greg KH
2009-09-16 7:38 ` Anthony Viallard
2009-09-16 13:19 ` Greg KH
2 siblings, 0 replies; 4+ messages in thread
From: Greg KH @ 2009-09-15 15:28 UTC (permalink / raw)
To: linux-hotplug
On Tue, Sep 15, 2009 at 11:13:43AM +0200, Anthony Viallard wrote:
> Hello list,
>
> I'm working on a 3G USB dongle which offer tty to communicate with him.
>
> I need to start a service when this dongle is plugged to my system. This
> service uses tty (there are 4 tty (diag, cmd, data and for voice). So, i
> need to waiting the complete insertion of the USB dongle before
> launching it.
>
> For now, i'm waiting the last tty (ttyUSB3) event, sleep 1 second and
> launch the service. But i think my solution is pretty crap.
>
> Is there a better way to do this ?
>
> (I'm working with old architecture of hotplug: /bin/hotplug script which
> launch /etc/hotplug.d/${SUBSYSTEM}/ scripts...)
That architecture is obsolete, and is not shipped, or supported by any
distro or developer, so you are on your own if you want to rely and use
it.
good luck,
greg k-h
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Waiting complete insertion of usb device
2009-09-15 9:13 Waiting complete insertion of usb device Anthony Viallard
2009-09-15 15:28 ` Greg KH
@ 2009-09-16 7:38 ` Anthony Viallard
2009-09-16 13:19 ` Greg KH
2 siblings, 0 replies; 4+ messages in thread
From: Anthony Viallard @ 2009-09-16 7:38 UTC (permalink / raw)
To: linux-hotplug
Le 15/09/2009 17:28, Greg KH a écrit :
> On Tue, Sep 15, 2009 at 11:13:43AM +0200, Anthony Viallard wrote:
>
>> Hello list,
>>
>> I'm working on a 3G USB dongle which offer tty to communicate with him.
>>
>> I need to start a service when this dongle is plugged to my system. This
>> service uses tty (there are 4 tty (diag, cmd, data and for voice). So, i
>> need to waiting the complete insertion of the USB dongle before
>> launching it.
>>
>> For now, i'm waiting the last tty (ttyUSB3) event, sleep 1 second and
>> launch the service. But i think my solution is pretty crap.
>>
>> Is there a better way to do this ?
>>
>> (I'm working with old architecture of hotplug: /bin/hotplug script which
>> launch /etc/hotplug.d/${SUBSYSTEM}/ scripts...)
>>
> That architecture is obsolete, and is not shipped, or supported by any
> distro or developer, so you are on your own if you want to rely and use
> it.
>
>
do you mean my problem will be solved if i use udev ?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Waiting complete insertion of usb device
2009-09-15 9:13 Waiting complete insertion of usb device Anthony Viallard
2009-09-15 15:28 ` Greg KH
2009-09-16 7:38 ` Anthony Viallard
@ 2009-09-16 13:19 ` Greg KH
2 siblings, 0 replies; 4+ messages in thread
From: Greg KH @ 2009-09-16 13:19 UTC (permalink / raw)
To: linux-hotplug
On Wed, Sep 16, 2009 at 09:38:56AM +0200, Anthony Viallard wrote:
> Le 15/09/2009 17:28, Greg KH a écrit :
> > On Tue, Sep 15, 2009 at 11:13:43AM +0200, Anthony Viallard wrote:
> >
> >> Hello list,
> >>
> >> I'm working on a 3G USB dongle which offer tty to communicate with him.
> >>
> >> I need to start a service when this dongle is plugged to my system. This
> >> service uses tty (there are 4 tty (diag, cmd, data and for voice). So, i
> >> need to waiting the complete insertion of the USB dongle before
> >> launching it.
> >>
> >> For now, i'm waiting the last tty (ttyUSB3) event, sleep 1 second and
> >> launch the service. But i think my solution is pretty crap.
> >>
> >> Is there a better way to do this ?
> >>
> >> (I'm working with old architecture of hotplug: /bin/hotplug script which
> >> launch /etc/hotplug.d/${SUBSYSTEM}/ scripts...)
> >>
> > That architecture is obsolete, and is not shipped, or supported by any
> > distro or developer, so you are on your own if you want to rely and use
> > it.
> >
> >
> do you mean my problem will be solved if i use udev ?
It will make things easier, yes.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-09-16 13:19 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-15 9:13 Waiting complete insertion of usb device Anthony Viallard
2009-09-15 15:28 ` Greg KH
2009-09-16 7:38 ` Anthony Viallard
2009-09-16 13:19 ` Greg KH
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.