Linux SCSI subsystem development
 help / color / mirror / Atom feed
* scsi scan: INQUIRY result too short (5), using 36
@ 2013-07-24 18:53 Tony Luck
  2013-07-24 19:02 ` Tony Luck
  2013-07-24 19:43 ` James Bottomley
  0 siblings, 2 replies; 4+ messages in thread
From: Tony Luck @ 2013-07-24 18:53 UTC (permalink / raw)
  To: James Bottomley; +Cc: linux-scsi, Linux Kernel Mailing List

[-- Attachment #1: Type: text/plain, Size: 472 bytes --]

v3.10 used to boot on this machine, linus latest doesn't.  git bisect
points to this commit.

commit e73823f7a2c921dcf068d34ea03bd682498d9e42
Author: James Bottomley <JBottomley@Parallels.com>
Date:   Tue May 7 15:38:18 2013 -0700

    [SCSI] libsas: implement > 16 byte CDB support

See attached console log for all the gory details.

Let me know if you need any other information about
this machine or its config that isn't easily deducible
from the console log.

-Tony

[-- Attachment #2: dmesg --]
[-- Type: application/octet-stream, Size: 113931 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: scsi scan: INQUIRY result too short (5), using 36
  2013-07-24 18:53 scsi scan: INQUIRY result too short (5), using 36 Tony Luck
@ 2013-07-24 19:02 ` Tony Luck
  2013-07-24 19:43 ` James Bottomley
  1 sibling, 0 replies; 4+ messages in thread
From: Tony Luck @ 2013-07-24 19:02 UTC (permalink / raw)
  To: James Bottomley; +Cc: linux-scsi, Linux Kernel Mailing List

Oops ... forgot final step.  That commit does revert cleanly (at least
git did not grumble when I asked it to revert).  The resulting kernel
builds cleanly and boots without seeing this problem.

-Tony

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: scsi scan: INQUIRY result too short (5), using 36
  2013-07-24 18:53 scsi scan: INQUIRY result too short (5), using 36 Tony Luck
  2013-07-24 19:02 ` Tony Luck
@ 2013-07-24 19:43 ` James Bottomley
  2013-07-24 20:14   ` Tony Luck
  1 sibling, 1 reply; 4+ messages in thread
From: James Bottomley @ 2013-07-24 19:43 UTC (permalink / raw)
  To: Tony Luck; +Cc: linux-scsi, Linux Kernel Mailing List

On Wed, 2013-07-24 at 11:53 -0700, Tony Luck wrote:
> v3.10 used to boot on this machine, linus latest doesn't.  git bisect
> points to this commit.
> 
> commit e73823f7a2c921dcf068d34ea03bd682498d9e42
> Author: James Bottomley <JBottomley@Parallels.com>
> Date:   Tue May 7 15:38:18 2013 -0700
> 
>     [SCSI] libsas: implement > 16 byte CDB support
> 
> See attached console log for all the gory details.
> 
> Let me know if you need any other information about
> this machine or its config that isn't easily deducible
> from the console log.

Oops, apparently no-one I cc'd at intel actually bothered to check the
patch for the isci driver.  The looks to be that sci_swab32_cpy needs
multiples of four, so for commands that aren't that, it's rounding the
wrong way.  Does this fix it?

James

---

diff --git a/drivers/scsi/isci/request.c b/drivers/scsi/isci/request.c
index 7b08215..99d2930 100644
--- a/drivers/scsi/isci/request.c
+++ b/drivers/scsi/isci/request.c
@@ -185,7 +185,7 @@ static void sci_io_request_build_ssp_command_iu(struct isci_request *ireq)
 	cmd_iu->_r_c = 0;
 
 	sci_swab32_cpy(&cmd_iu->cdb, task->ssp_task.cmd->cmnd,
-		       task->ssp_task.cmd->cmd_len / sizeof(u32));
+		       (task->ssp_task.cmd->cmd_len+3) / sizeof(u32));
 }
 
 static void sci_task_request_build_ssp_task_iu(struct isci_request *ireq)

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: scsi scan: INQUIRY result too short (5), using 36
  2013-07-24 19:43 ` James Bottomley
@ 2013-07-24 20:14   ` Tony Luck
  0 siblings, 0 replies; 4+ messages in thread
From: Tony Luck @ 2013-07-24 20:14 UTC (permalink / raw)
  To: James Bottomley; +Cc: linux-scsi, Linux Kernel Mailing List

On Wed, Jul 24, 2013 at 12:43 PM, James Bottomley
<James.Bottomley@hansenpartnership.com> wrote:
> Oops, apparently no-one I cc'd at intel actually bothered to check the
> patch for the isci driver.  The looks to be that sci_swab32_cpy needs
> multiples of four, so for commands that aren't that, it's rounding the
> wrong way.  Does this fix it?

Yes. That fixes it.

Wrap whichever of:

Reported-by: Tony Luck <tony.luck@intel.com>

and/or

Tested-by: Tony Luck <tony.luck@intel.com>

around that patch and ship it!

Thanks for the fast fix.

-Tony

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-07-24 20:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-24 18:53 scsi scan: INQUIRY result too short (5), using 36 Tony Luck
2013-07-24 19:02 ` Tony Luck
2013-07-24 19:43 ` James Bottomley
2013-07-24 20:14   ` Tony Luck

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox