Re: [PATCH 4 of 4] sd: Correctly handle 6-byte commands with DIX

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

 



>>>>> "Matthew" == Matthew Wilcox <matthew@xxxxxx> writes:

>> + BUG_ON(dif && (scmd->cmnd[0] == READ_6 || scmd->cmnd[0] ==
>>  	WRITE_6));

Matthew> This BUG_ON gave me a 'Huh?' moment.  I immediately wondered if
Matthew> it was user-triggerable.  The answer is "no, this is kosher".
Matthew> sd_dif_op() is only called from sd.c where it has chosen which
Matthew> READ_*/WRITE_* opcode to set up, and it would indeed be an
Matthew> internal bug for this combination of conditions to exist.

Yep, I recently had to track down a bug where we had accidentally (for
completely different reasons) switched to 6-byte commands.  The code in
the completion path that triggered this condition is now gone, thanks to
Alan.  But I left the BUG_ON in place because it was no fun track this
down.

-- 
Martin K. Petersen	Oracle Linux Engineering
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux