Re: [PATCH 2/3] target: Fix error checking for UNMAP commands

2013-02-13 Thread Nicholas A. Bellinger
On Fri, 2013-02-08 at 15:18 -0800, Roland Dreier wrote: > From: Roland Dreier > > SBC-3 (revision 35) says: > > The PARAMETER LIST LENGTH field specifies the length in bytes of the > UNMAP parameter list that is available to be transferred from the > Data-Out Buffer. If the parameter

Re: [PATCH 2/3] target: Fix error checking for UNMAP commands

2013-02-09 Thread Roland Dreier
On Sat, Feb 9, 2013 at 1:23 AM, Chris Boot wrote: >> + case TCM_PARAMETER_LIST_LENGTH_ERROR: >> + /* CURRENT ERROR */ >> + buffer[0] = 0x70; >> + buffer[SPC_ADD_SENSE_LEN_OFFSET] = 10; >> + /* ILLEGAL REQUEST */ >> + buffe

Re: [PATCH 2/3] target: Fix error checking for UNMAP commands

2013-02-09 Thread Chris Boot
On 08/02/2013 23:18, Roland Dreier wrote: diff --git a/drivers/target/target_core_iblock.c b/drivers/target/target_core_iblock.c index b526d23..b72ca5b 100644 --- a/drivers/target/target_core_iblock.c +++ b/drivers/target/target_core_iblock.c @@ -2674,6 +2675,15 @@ transport_send_check_condition

[PATCH 2/3] target: Fix error checking for UNMAP commands

2013-02-08 Thread Roland Dreier
From: Roland Dreier SBC-3 (revision 35) says: The PARAMETER LIST LENGTH field specifies the length in bytes of the UNMAP parameter list that is available to be transferred from the Data-Out Buffer. If the parameter list length is greater than zero and less than 0008h (i.e., eight