Re: [VERY EARLY RFC 01/13] scsi: use host_byte() accessor

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

 



On Wed, 18 Apr 2018, Johannes Thumshirn wrote:

> --- a/drivers/scsi/dc395x.c
> +++ b/drivers/scsi/dc395x.c
> @@ -3473,7 +3473,7 @@ static void srb_done(struct AdapterCtlBlk *acb, struct DeviceCtlBlk *dcb,
>  
>  	/*if( srb->cmd->cmnd[0] == INQUIRY && */
>  	/*  (host_byte(cmd->result) == DID_OK || status_byte(cmd->result) & CHECK_CONDITION) ) */
> -		if ((cmd->result == (DID_OK << 16)
> +		if ((host_byte(cmd->result) == DID_OK
>  		     || status_byte(cmd->result) &
>  		     CHECK_CONDITION)) {
>  			if (!dcb->init_tcq_flag) {

That's not quite the same. The old test is effectively cmd->result == 0. 
Maybe this should be a separate patch?

-- 



[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