Re: [PATCH 14/42] scsi: add scsi_result_is_good()

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

 



On 4/21/21 11:10 PM, Bart Van Assche wrote:
On 4/21/21 10:47 AM, Hannes Reinecke wrote:
+static inline bool scsi_result_is_good(struct scsi_cmnd *cmd)
+{
+    return (cmd->result == 0);
+}

Do we really need an inline function to compare an integer with zero? How about open-coding this comparison in the callers of this function?

My approach is to avoid direct access to the 'result' field, as the definition of which is about to change.

But as this is not part of _this_ patchset I'll drop this patch for the next round.

Cheers,

Hannes
--
Dr. Hannes Reinecke                Kernel Storage Architect
hare@xxxxxxx                              +49 911 74053 688
SUSE Software Solutions GmbH, Maxfeldstr. 5, 90409 Nürnberg
HRB 36809 (AG Nürnberg), Geschäftsführer: Felix Imendörffer



[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