Re: [PATCH v2] Fix DID_OK handling in __scsi_error_from_host_byte()

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

 



On Thu, Apr 05, 2018 at 08:43:18AM +0200, Hannes Reinecke wrote:
> And a further nit-pick: the function is called
> __scsi_error_from_host_byte(), so it's only logical that it would only
> check the host_byte().
> What's wrong is the _usage_ here; after calling
> __scsi_error_from_host_byte() we need to check if the _other_ bits of
> the results are non-zero to end up with a valid result.
> 
> Hence I would advocate to either rename this function
> (__scsi_error_from_result() ?) or evaluate the remaining bits outside
> this function.
> 
> But I would advocate for the former; otherwise the same issue will crop
> up again in the future.

Please also drop the pointless double underscore prefix while at it,
otherwise fully agreed.



[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