From: Nicholas Bellinger Date: Fri, 2 Nov 2012 01:43:03 +0000 (-0700) Subject: target: Fix incorrect starting offset after MODE_SENSE refactoring X-Git-Tag: v3.8-rc1~94^2~34 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fecae40abb1ae9218bdbaa8b8e30bfb5ae43f522;p=pandora-kernel.git target: Fix incorrect starting offset after MODE_SENSE refactoring This patch fixes a new off-by-one bug in the hardcoded starting offset of spc_emulate_modesense() code that causes BLOCK DESCRIPTOR to be incorrectly written within the MEDIUM TYPE buffer area of the mode parameter header. According to spc4r30, Section 7.5.4, BLOCK DESCRIPTOR for MODE_SENSE_10 starts at byte 3, and BLOCK_DESCRIPTOR for MODE_SENSE (6) starts at byte 2. (roland: add MODE DATA LENGTH + MEDIUM TYPE offset comment) Cc: Roland Dreier Cc: Christoph Hellwig Cc: Douglas Gilbert Signed-off-by: Nicholas Bellinger --- Reading git-diff-tree failed