Thread (7 messages) 7 messages, 2 authors, 2005-10-24

Re: infinite loop with 36 Byte inquiry (sbp2 regression in 2.6.14-rcX)

From: Stefan Richter <stefanr@s5r6.in-berlin.de>
Date: 2005-10-24 19:07:20

James Bottomley wrote:
Like I said, I think that's because you send an orb to the device with a
command indicated length of 36 but a buffer length of 37
It happens regardless of what I force sbp2_send_command() to do:
	request_bufflen = cmd[4] = 0x24;
or
	request_bufflen = cmd[4];
or none of that.
I don't see any loops in the lun probing routines.  For UNIT_ATTENTION
to inquiry, we should retry three times and then give up.  If you enable
debugging at the SCSI layer, that might give a better indication of
what's going on.
Yes, I will do so.
There's an #if 0 around an incorrect piece of code that would return
DID_BUS_BUSY in this condition, you don't have that enabled, do you?

DID_BUS_BUSY is a dangerous reply because it causes an immediate retry
without decrementing the retry count.  If you return it for a condition
that never clears, it used to cause a hang.  Now it should actually exit
the loop after the command times out (6 seconds, I think).
The #if 0 block is still deactivated here.

Thanks a lot for the advice. I will post what I find out.
-- 
Stefan Richter
-=====-=-=-= =-=- ==---
http://arcgraph.de/sr/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help