[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [PATCH v3 02/12] block/iscsi:Remove redundant statement in iscsi_ope
From: |
Chenqun (kuhn) |
Subject: |
RE: [PATCH v3 02/12] block/iscsi:Remove redundant statement in iscsi_open() |
Date: |
Wed, 11 Mar 2020 02:04:23 +0000 |
>-----Original Message-----
>From: Laurent Vivier [mailto:address@hidden]
>Sent: Tuesday, March 10, 2020 11:02 PM
>To: Kevin Wolf <address@hidden>; Chenqun (kuhn)
><address@hidden>
>Cc: address@hidden; Zhanghailiang
><address@hidden>; address@hidden; Peter Lieven
><address@hidden>; address@hidden; Max Reitz <address@hidden>;
>Ronnie Sahlberg <address@hidden>; Euler Robot
><address@hidden>; Paolo Bonzini <address@hidden>
>Subject: Re: [PATCH v3 02/12] block/iscsi:Remove redundant statement in
>iscsi_open()
>
>Le 10/03/2020 à 15:26, Kevin Wolf a écrit :
>> Am 02.03.2020 um 14:07 hat Chen Qun geschrieben:
>>> Clang static code analyzer show warning:
>>> block/iscsi.c:1920:9: warning: Value stored to 'flags' is never read
>>> flags &= ~BDRV_O_RDWR;
>>> ^ ~~~~~~~~~~~~
>>>
>>> Reported-by: Euler Robot <address@hidden>
>>> Signed-off-by: Chen Qun <address@hidden>
>>> ---
>>> Cc: Ronnie Sahlberg <address@hidden>
>>> Cc: Paolo Bonzini <address@hidden>
>>> Cc: Peter Lieven <address@hidden>
>>> Cc: Kevin Wolf <address@hidden>
>>> Cc: Max Reitz <address@hidden>
>>>
>>> v1->v2:
>>> Keep the 'flags' then use it(Base on Kevin's comments).
>>
>> I think this patch wants a different subject line now.
>
Yes, it needs a more appropriate subject.
>It needs also a better explanation in the commit message and should not go
>through trivial as the change is not obvious.
>
OK , I will update the commit message base on existing comments.
Thanks.
>Thanks,
>Laurent
>
>>
>>> diff --git a/block/iscsi.c b/block/iscsi.c index
>>> 682abd8e09..50bae51700 100644
>>> --- a/block/iscsi.c
>>> +++ b/block/iscsi.c
>>> @@ -2002,7 +2002,7 @@ static int iscsi_open(BlockDriverState *bs, QDict
>*options, int flags,
>>> iscsilun->cluster_size = iscsilun->bl.opt_unmap_gran *
>>> iscsilun->block_size;
>>> if (iscsilun->lbprz) {
>>> - ret = iscsi_allocmap_init(iscsilun, bs->open_flags);
>>> + ret = iscsi_allocmap_init(iscsilun, flags);
>>> }
>>> }
>>
>> The code looks good.
>>
>> Reviewed-by: Kevin Wolf <address@hidden>
>>
>>
[PATCH v3 06/12] display/pxa2xx_lcd: Remove redundant statement in pxa2xx_palette_parse(), Chen Qun, 2020/03/02
[PATCH v3 04/12] scsi/esp-pci: Remove redundant statement in esp_pci_io_write(), Chen Qun, 2020/03/02
[PATCH v3 03/12] block/file-posix: Remove redundant statement in raw_handle_perm_lock(), Chen Qun, 2020/03/02
[PATCH v3 09/12] dma/xlnx-zdma: Remove redundant statement in zdma_write_dst(), Chen Qun, 2020/03/02