[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e87746e6-813e-7c0e-e21e-5921e759da5d@redhat.com>
Date: Thu, 9 Jul 2020 19:25:47 +0200
From: Paolo Bonzini <pbonzini@...hat.com>
To: Markus Elfring <Markus.Elfring@....de>,
Xianting Tian <xianting_tian@....com>,
linux-scsi@...r.kernel.org,
virtualization@...ts.linux-foundation.org
Cc: kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org,
"James E. J. Bottomley" <jejb@...ux.ibm.com>,
Jason Wang <jasowang@...hat.com>,
"Martin K. Petersen" <martin.petersen@...cle.com>,
"Michael S. Tsirkin" <mst@...hat.com>,
Stefan Hajnoczi <stefanha@...hat.com>
Subject: Re: [PATCH] scsi: virtio_scsi: Remove unnecessary condition checks
On 09/07/20 19:16, Markus Elfring wrote:
>> + mempool_destroy(virtscsi_cmd_pool);
>> + virtscsi_cmd_pool = NULL;
>> + kmem_cache_destroy(virtscsi_cmd_cache);
>> + virtscsi_cmd_cache = NULL;
>> return ret;
>> }
>
> How do you think about to add a jump target so that the execution
> of a few statements can be avoided according to a previous
> null pointer check?
The point of the patch is precisely to simplify the code, executing a
couple more instruction is not an issue.
Paolo
Powered by blists - more mailing lists