2004-10-20 06:19:44

by Norbert Preining

[permalink] [raw]
Subject: Instances of visor us devices are not deleted (2.6.9-rc4-mm1)

Hi USB developers!

I have the following problem with 2.6.9-rc4-mm1 which includes bk-usb:

Everytime I sync my palm I get a new device id:

...start sync...
usb 4-2.1: new full speed USB device using address 8
visor 4-2.1:1.0: Handspring Visor / Palm OS converter detected
usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB2
usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB3
...
...many usb usb2: string descriptor 0 read error: -113 ...
...
...end of sync...
usb 4-2.1: USB disconnect, address 8
visor 4-2.1:1.0: device disconnected
visor ttyUSB3: visor_write - usb_submit_urb(write bulk) failed with status = -19
...new sync...
usb 4-2.1: new full speed USB device using address 9
visor 4-2.1:1.0: Handspring Visor / Palm OS converter detected
usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB4
usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB5

etc etc.

Is this a known problem?

(debian/sid, 2.6.9-rc4-mm1)

Best wishes

Norbert

-------------------------------------------------------------------------------
Norbert Preining <preining AT logic DOT at> Technische Universit?t Wien
gpg DSA: 0x09C5B094 fp: 14DF 2E6C 0307 BE6D AD76 A9C0 D2BF 4AA3 09C5 B094
-------------------------------------------------------------------------------
WIDDICOMBE (n.)
The sort of person who impersonates trim phones.
--- Douglas Adams, The Meaning of Liff


2004-10-20 07:23:38

by Greg KH

[permalink] [raw]
Subject: Re: Instances of visor us devices are not deleted (2.6.9-rc4-mm1)

On Wed, Oct 20, 2004 at 08:16:47AM +0200, Norbert Preining wrote:
> Hi USB developers!
>
> I have the following problem with 2.6.9-rc4-mm1 which includes bk-usb:
>
> Everytime I sync my palm I get a new device id:
>
> ...start sync...
> usb 4-2.1: new full speed USB device using address 8
> visor 4-2.1:1.0: Handspring Visor / Palm OS converter detected
> usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB2
> usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB3
> ...
> ...many usb usb2: string descriptor 0 read error: -113 ...
> ...
> ...end of sync...
> usb 4-2.1: USB disconnect, address 8
> visor 4-2.1:1.0: device disconnected
> visor ttyUSB3: visor_write - usb_submit_urb(write bulk) failed with status = -19
> ...new sync...
> usb 4-2.1: new full speed USB device using address 9
> visor 4-2.1:1.0: Handspring Visor / Palm OS converter detected
> usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB4
> usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB5
>
> etc etc.
>
> Is this a known problem?

Hm, no it isn't. Are you sure that userspace doesn't still have the
device nodes open? If they do, the ttyUSB number will not be released
until that happens.

thanks,

greg k-h

2004-10-20 11:27:40

by Norbert Preining

[permalink] [raw]
Subject: Re: Instances of visor us devices are not deleted (2.6.9-rc4-mm1)

Hi Greg!

On Mit, 20 Okt 2004, Greg KH wrote:
> Hm, no it isn't. Are you sure that userspace doesn't still have the
> device nodes open? If they do, the ttyUSB number will not be released
> until that happens.

Ah, ok. So the culprit is gnome-pilot listening for HotSync events.

I thought that as soon as the unit/usb device is disconnected, also the
device numbers are released.

But then: How to cope with problems like this? REcurring plugging and
unplugging and a program listening to this?

Is it possible to have
/dev/pilot -> /dev/ttyUSB1
and gnome-pilot opens /dev/pilot. Will then every new hot sync also
create other devices?

Best wishes

Norbert

-------------------------------------------------------------------------------
Norbert Preining <preining AT logic DOT at> Technische Universit?t Wien
gpg DSA: 0x09C5B094 fp: 14DF 2E6C 0307 BE6D AD76 A9C0 D2BF 4AA3 09C5 B094
-------------------------------------------------------------------------------
Yesterday it worked.
Today it is not working.
Windows is like that.
--- Windows Error Haiku

2004-10-21 00:29:45

by Greg KH

[permalink] [raw]
Subject: Re: Instances of visor us devices are not deleted (2.6.9-rc4-mm1)

On Wed, Oct 20, 2004 at 01:18:00PM +0200, Norbert Preining wrote:
> Hi Greg!
>
> On Mit, 20 Okt 2004, Greg KH wrote:
> > Hm, no it isn't. Are you sure that userspace doesn't still have the
> > device nodes open? If they do, the ttyUSB number will not be released
> > until that happens.
>
> Ah, ok. So the culprit is gnome-pilot listening for HotSync events.
>
> I thought that as soon as the unit/usb device is disconnected, also the
> device numbers are released.

Nope, sorry.

> But then: How to cope with problems like this? REcurring plugging and
> unplugging and a program listening to this?

fix the userspace program :)

Good luck,

greg k-h

2004-10-21 14:27:47

by Kurt Wall

[permalink] [raw]
Subject: Re: Instances of visor us devices are not deleted (2.6.9-rc4-mm1)

On Wed, Oct 20, 2004 at 12:00:56AM -0700, Greg KH took 41 lines to write:
> On Wed, Oct 20, 2004 at 08:16:47AM +0200, Norbert Preining wrote:
> > Hi USB developers!
> >
> > I have the following problem with 2.6.9-rc4-mm1 which includes bk-usb:
> >
> > Everytime I sync my palm I get a new device id:
> >
> > ...start sync...
> > usb 4-2.1: new full speed USB device using address 8
> > visor 4-2.1:1.0: Handspring Visor / Palm OS converter detected
> > usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB2
> > usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB3
> > ...
> > ...many usb usb2: string descriptor 0 read error: -113 ...
> > ...
> > ...end of sync...
> > usb 4-2.1: USB disconnect, address 8
> > visor 4-2.1:1.0: device disconnected
> > visor ttyUSB3: visor_write - usb_submit_urb(write bulk) failed with status = -19
> > ...new sync...
> > usb 4-2.1: new full speed USB device using address 9
> > visor 4-2.1:1.0: Handspring Visor / Palm OS converter detected
> > usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB4
> > usb 4-2.1: Handspring Visor / Palm OS converter now attached to ttyUSB5
> >
> > etc etc.
> >
> > Is this a known problem?
>
> Hm, no it isn't. Are you sure that userspace doesn't still have the
> device nodes open? If they do, the ttyUSB number will not be released
> until that happens.

I'm seeing the same thing here, but without the read errors:

drivers/usb/serial/usb-serial.c: USB Serial support registered for
Handspring Visor / Palm OS
drivers/usb/serial/usb-serial.c: USB Serial support registered for Sony
Clie 3.5
drivers/usb/serial/usb-serial.c: USB Serial support registered for Sony
Clie 5.0
usbcore: registered new driver visor
drivers/usb/serial/visor.c: USB HandSpring Visor / Palm OS driver v2.1
usb 1-2: new full speed USB device using address 2
visor 1-2:1.0: Handspring Visor / Palm OS converter detected
usb 1-2: Handspring Visor / Palm OS converter now attached to ttyUSB0
usb 1-2: Handspring Visor / Palm OS converter now attached to ttyUSB1
usb 1-2: USB disconnect, address 2
visor ttyUSB0: Handspring Visor / Palm OS converter now disconnected from
ttyUSB0
visor ttyUSB1: Handspring Visor / Palm OS converter now disconnected from
ttyUSB1
visor 1-2:1.0: device disconnected

Kurt
--
Furious activity is no substitute for understanding.
-- H. H. Williams