Re: regarding usb reset of an interface while probe is happening

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Nov 22, 2011 at 2:31 PM, Amit Nagal <helloin.amit@xxxxxxxxx> wrote:
>>> Also , i have not test the case with the above patch when usb audio
>>> streaming (capture ) is in progress
>>> and a usb reset is issued .
>>
>> Do you have a way to test that?
>>
>>        Regards
>>                Oliver
>>
>

(1 ) Hi ,  to test this , in one terminal , i  continously read  usb
audio interface ( /dev/dsp1) in a while loop ,
and in another terminal , i reset the usb device via a userspace program .
At the time of reset ,  read(/dev/dsp1) failed with error : : Broken pipe .

(2) Now , on linux machine , once read(/dev/dsp1) failed , i needed a
minimum of 150 ms delay before i can reopen
/dev/dsp1 successfully . if i donot provide this 150 ms delay , test
program fails to re-open /dev/dsp1 ,
and in dmesg i could see a line 0:1:1: usb_set_interface failed .

(3) i am enclosing the dmesg log when i donot provide 150 ms delay
before reopen /dev/dsp1  :
dmesg log with 150 ms delay case remains same except line  0:1:1:
usb_set_interface failed .

[ 1266.319331] ehci_hcd 0000:00:1d.7: GetStatus port:5 status 001005 0
 ACK POWER sig=se0 PE CONNECT
[ 1266.370024] usb 2-5: reset high-speed USB device number 2 using ehci_hcd
[ 1266.378201] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 1
[ 1266.378324] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 2
[ 1266.378449] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 3
[ 1266.378574] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 4
[ 1266.378699] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 5
[ 1266.378824] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 6
[ 1266.378949] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 7
[ 1266.379075] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 8
[ 1266.379200] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 9
[ 1266.379324] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 10
[ 1266.379449] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 11
[ 1266.379574] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 12
[ 1266.379699] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 13
[ 1266.379823] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 14
[ 1266.379949] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 15
[ 1266.380074] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 16
[ 1266.380198] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 17
[ 1266.380324] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 18
[ 1266.380449] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 19
[ 1266.380574] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 20
[ 1266.380699] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 21
[ 1266.380824] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 22
[ 1266.380949] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 23
[ 1266.381075] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 24
[ 1266.381200] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 25
[ 1266.381324] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 26
[ 1266.381450] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 27
[ 1266.381574] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 28
[ 1266.381699] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 29
[ 1266.381824] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 30
[ 1266.381949] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 31
[ 1266.382074] ehci_hcd 0000:00:1d.7: devpath 5 ep0out 3strikes
[ 1266.382576] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 1
[ 1266.382699] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 2
[ 1266.382824] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 3
[ 1266.382949] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 4
[ 1266.383074] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 5
[ 1266.383200] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 6
[ 1266.383325] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 7
[ 1266.383449] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 8
[ 1266.383574] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 9
[ 1266.383699] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 10
[ 1266.383824] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 11
[ 1266.383949] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 12
[ 1266.384074] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 13
[ 1266.384200] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 14
[ 1266.384324] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 15
[ 1266.384449] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 16
[ 1266.384574] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 17
[ 1266.384699] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 18
[ 1266.384824] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 19
[ 1266.384948] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 20
[ 1266.385075] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 21
[ 1266.385200] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 22
[ 1266.385323] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 23
[ 1266.385449] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 24
[ 1266.385573] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 25
[ 1266.385699] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 26
[ 1266.385824] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 27
[ 1266.385948] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 28
[ 1266.386075] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 29
[ 1266.386200] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 30
[ 1266.386324] ehci_hcd 0000:00:1d.7: detected XactErr len 0/8 retry 31
[ 1266.386449] ehci_hcd 0000:00:1d.7: devpath 5 ep0out 3strikes
[ 1266.386460] 0:1:1: usb_set_interface failed
[ 1266.421197] ehci_hcd 0000:00:1d.7: port 5 high speed
[ 1266.421202] ehci_hcd 0000:00:1d.7: GetStatus port:5 status 001005 0
 ACK POWER sig=se0 PE CONNECT
[ 1267.659833] 2:1:1: cannot get freq at ep 0x81


(4) i have a query . At the time of reset , read(/dev/dsp1) fails with
error broken pipe ,
Even when we donot apply the patch also , still usb audio modules gets
unbind and then rebinds .
As far as userspace  is concerned ,  if some I/O is going on , it will
feel the same effect of disconnect / broken pipe
with or without the patch applied.

i want to know what extra advantage  will the  implemention of
pre-reset and post-reset functionality
provide as compared to bind-unbind approach ?





Thanx & Regards
Amit Nagal
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux