Re: [PATCH 5/7] target: Refactor MODE SENSE emulation

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

 



On Thu, Nov 1, 2012 at 6:42 PM, Nicholas A. Bellinger
<nab@xxxxxxxxxxxxxxx> wrote:
> The length (buffer offset) assignment here is off by one and causes
> BLOCK DESCRIPTOR to be incorrectly written into the MEDIUM TYPE byte
> area for 10 + 6 byte mode parameter headers according to SPC-4.
>
> Here's an incremental patch that I'm applying into for-next that allows
> sg_mode to work again.
>
> I'll assume this is a untested bug, right..?  Unless there is an
> initiator that actually gets this wrong somehow..?

Sorry, it was my fault when I was cleaning up the patches for review
before posting them.  The tree that I tested had:

        length = ten ? 2 : 1;

        /* MEDIUM TYPE is always 0 for SBC */
        ++length;

        /* DEVICE-SPECIFIC PARAMETER */

and I accidentally deleted those two middle lines about medium type
before posting.

Your fixup is fine too, although putting a comment about medium type
might be worthwhile.

 - R.
--
To unsubscribe from this list: send the line "unsubscribe target-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux SCSI]     [Kernel Newbies]     [Linux SCSI Target Infrastructure]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Device Mapper]

  Powered by Linux