On 06/28/16 11:17, Ken Merry wrote:
> This is incorrect.  It should be scsi_ulto4b() instead.
> 
> The dxfer_len argument to scsi_persistent_reserve_out() is a uint32_t, and 
> the length field in the CDB structure is 4 bytes long.
> 
> Sorry I didn’t get around to commenting on the PR, otherwise I would have 
> caught this previously.
> 
> Ken
> — 
> Ken Merry
> k...@freebsd.org

Ok, I shall revert this then generate a new diff for your review and
submission to re for commit.

sean

> 
> 
> 
>> On Jun 28, 2016, at 2:08 PM, Sean Bruno <sbr...@freebsd.org> wrote:
>>
>> Author: sbruno
>> Date: Tue Jun 28 18:08:47 2016
>> New Revision: 302253
>> URL: https://svnweb.freebsd.org/changeset/base/302253
>>
>> Log:
>>  Correct PERSISTENT RESERVE OUT command and populate scsi_cmd->length.
>>
>>  PR:         202625
>>  Submitted by:       niakr...@gmail.com
>>  Reviewed by:        scottl
>>  Approved by:        re (hrs)
>>  MFC after:  2 weeks
>>
>> Modified:
>>  head/sys/cam/scsi/scsi_all.c
>>
>> Modified: head/sys/cam/scsi/scsi_all.c
>> ==============================================================================
>> --- head/sys/cam/scsi/scsi_all.c     Tue Jun 28 16:43:23 2016        
>> (r302252)
>> +++ head/sys/cam/scsi/scsi_all.c     Tue Jun 28 18:08:47 2016        
>> (r302253)
>> @@ -8788,6 +8788,7 @@ scsi_persistent_reserve_out(struct ccb_s
>>      scsi_cmd->opcode = PERSISTENT_RES_OUT;
>>      scsi_cmd->action = service_action;
>>      scsi_cmd->scope_type = scope | res_type;
>> +    scsi_ulto2b(dxfer_len, scsi_cmd->length);
>>
>>      cam_fill_csio(csio,
>>                    retries,
>>
> 
> 

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to