[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <488E29DD.4050303@belbone.be>
Date: Mon, 28 Jul 2008 22:19:41 +0200
From: Cédric Godin <cedric@...bone.be>
To: Alan Stern <stern@...land.harvard.edu>
CC: James Bottomley <James.Bottomley@...senPartnership.com>,
Linux Kernel <linux-kernel@...r.kernel.org>,
SCSI Kernel <linux-scsi@...r.kernel.org>
Subject: Re: [SCSI] can't plug Nokia 5300 anymore (bisected)
Alan Stern wrote:
> On Mon, 28 Jul 2008, Cédric Godin wrote:
>
>
>>>>>> Hello,
>>>>>>
>>>>>> since 2 or 3 -git kernels (Linus tree) I have a problem with my laptop
>>>>>> and its connection through USB to a nokia 5300 gsm.
>>>>>>
>>>>>> The logs show me a endless loop (until i unplug my USB cable) of
>>>>>> following messages :
>>>>>>
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] ASC=0x0 ASCQ=0x0
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] Sense Key : 0x0 [current]
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] ASC=0x0 ASCQ=0x0
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] Sense Key : 0x0 [current]
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] ASC=0x0 ASCQ=0x0
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] Sense Key : 0x0 [current]
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] ASC=0x0 ASCQ=0x0
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] Sense Key : 0x0 [current]
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] ASC=0x0 ASCQ=0x0
>>>>>> Jul 25 15:19:14 enea sd 2:0:0:0: [sdb] Sense Key : 0x0 [current]
>>>>>>
>>>>>> I bisected the kernel and found the following commit as result :
>>>>>>
>>>>>> 427e59f09fdba387547106de7bab980b7fff77be is first bad commit
>>>>>> commit 427e59f09fdba387547106de7bab980b7fff77be
>>>>>> Author: James Bottomley <James.Bottomley@...senPartnership.com>
>>>>>> Date: Sat Mar 8 18:24:17 2008 -0600
>>>>>>
>>>>>> [SCSI] make use of the residue value
>>>>>>
>>>>>> USB sometimes doesn't return an error but instead returns a residue
>>>>>> value indicating part (or all) of the command wasn't completed. So if
>>>>>> the driver _done() error processing indicates the command was fully
>>>>>> processed, subtract off the residue so that this USB error gets
>>>>>> propagated.
>>>>>>
>
>
>> That's me sending the wrong dmesg, sorry :-$
>>
>> Attached is the "good" one.
>>
>>
>>> see only one error, and the commit you found wouldn't have affected
>>> that error. More accurately, if the commit magnified the error into an
>>> endless loop, then without the commit the error would still have been
>>> present and would have caused data corruption.
>>>
>>> Anyway, it would be interesting to see what happens with the commit in
>>> place and the following patch applied. (The first part of the patch
>>> has already been accepted by James.)
>>>
>>>
>> Same problem.
>>
>
> Okay. The problem is one we've seen many times in the past: The device
> reports that it contains one sector more than it really does contain.
> When the system tries to access the non-existent "last" sector, all
> sorts of problems occur. In your case the device returned no data,
> together with an indication that a problem existed (Check Condition
> status) and no indication of what the problem actually was (no Sense
> data).
>
> The patch below should fix the problem.
>
> Alan Stern
>
>
>
> Index: usb-2.6/drivers/usb/storage/unusual_devs.h
> ===================================================================
> --- usb-2.6.orig/drivers/usb/storage/unusual_devs.h
> +++ usb-2.6/drivers/usb/storage/unusual_devs.h
> @@ -225,6 +225,13 @@ UNUSUAL_DEV( 0x0421, 0x0495, 0x0370, 0x
> US_SC_DEVICE, US_PR_DEVICE, NULL,
> US_FL_MAX_SECTORS_64 ),
>
> +/* Reported by Cedric Godin <cedric@...bone.be> */
> +UNUSUAL_DEV( 0x0421, 0x04b9, 0x0551, 0x0551,
> + "Nokia",
> + "5300",
> + US_SC_DEVICE, US_PR_DEVICE, NULL,
> + US_FL_FIX_CAPACITY ),
> +
> /* Reported by Olaf Hering <olh@...e.de> from novell bug #105878 */
> UNUSUAL_DEV( 0x0424, 0x0fdc, 0x0210, 0x0210,
> "SMSC",
>
>
it works, thanks !
Tested-by: Cedric Godin <cedric@...bone.be>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists