[PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Chen Qun posted 3 patches 2 weeks ago
Test docker-mingw@fedora passed
Test docker-quick@centos7 passed
Test checkpatch passed
Test FreeBSD passed
Test asan passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20200325025919.21316-1-kuhn.chenqun@huawei.com
Maintainers: Igor Mitsyanko <i.mitsyanko@gmail.com>, Paolo Bonzini <pbonzini@redhat.com>, Andrzej Zaborowski <balrogg@gmail.com>, Peter Maydell <peter.maydell@linaro.org>, Fam Zheng <fam@euphon.net>
hw/display/blizzard.c     | 10 ++++------
hw/scsi/esp-pci.c         |  1 +
hw/timer/exynos4210_mct.c |  4 ----
3 files changed, 5 insertions(+), 10 deletions(-)

[PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Posted by Chen Qun 2 weeks ago
v1->v2:
- Patch1: Add John Snow review comment.
- Patch9: Move the 'dst_type' declaration to while() statement.
- Patch12: Add Philippe Mathieu-Daudé review comment.
- Patch13: Move the 'set' declaration to the for() statement.

v2->v3:
- Patch1: Add Kevin Wolf review comment.
- Patch2: Keep the 'flags' then use it(Base on Kevin's comments).
- Patch3: Add Kevin Wolf review comment.
- Patch9: Add Francisco Iglesias and Alistair Francis review comment.
- Patch10: Juan Quintela has added it to the queue and delete it.
- Patch12->Patch11: Add Philippe Mathieu-Daudé review comment.
- Patch13->Patch12: Add Philippe Mathieu-Daudé review comment.

v3->v4:
- Deleted the patches that have been merged in the v3.
- Modify "scsi/esp-pci" Patch, use g_assert with variable size.

v4->v5:
- Patch1: Add Laurent Vivier review comment and change the subject.
- Patch2: Use extract16() instead of delete bit operation statement.
- Patch3: Add Laurent Vivier review comment.

Chen Qun (3):
  scsi/esp-pci: add g_assert() for fix clang analyzer warning in
    esp_pci_io_write()
  display/blizzard: use extract16() for fix clang analyzer warning in
    blizzard_draw_line16_32()
  timer/exynos4210_mct: Remove redundant statement in
    exynos4210_mct_write()

 hw/display/blizzard.c     | 10 ++++------
 hw/scsi/esp-pci.c         |  1 +
 hw/timer/exynos4210_mct.c |  4 ----
 3 files changed, 5 insertions(+), 10 deletions(-)

-- 
2.23.0



RE: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Posted by Chenqun (kuhn) 6 days ago
Ping!

This series has been reviewed.  Could someone please pick this up (e.g. qemu-trivial?)?

>-----Original Message-----
>From: Chenqun (kuhn)
>Sent: Wednesday, March 25, 2020 10:59 AM
>To: qemu-devel@nongnu.org; qemu-trivial@nongnu.org
>Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>; laurent@vivier.eu;
>philmd@redhat.com; Chenqun (kuhn) <kuhn.chenqun@huawei.com>
>Subject: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static
>code analyzer
>
>v1->v2:
>- Patch1: Add John Snow review comment.
>- Patch9: Move the 'dst_type' declaration to while() statement.
>- Patch12: Add Philippe Mathieu-Daud茅 review comment.
>- Patch13: Move the 'set' declaration to the for() statement.
>
>v2->v3:
>- Patch1: Add Kevin Wolf review comment.
>- Patch2: Keep the 'flags' then use it(Base on Kevin's comments).
>- Patch3: Add Kevin Wolf review comment.
>- Patch9: Add Francisco Iglesias and Alistair Francis review comment.
>- Patch10: Juan Quintela has added it to the queue and delete it.
>- Patch12->Patch11: Add Philippe Mathieu-Daud茅 review comment.
>- Patch13->Patch12: Add Philippe Mathieu-Daud茅 review comment.
>
>v3->v4:
>- Deleted the patches that have been merged in the v3.
>- Modify "scsi/esp-pci" Patch, use g_assert with variable size.
>
>v4->v5:
>- Patch1: Add Laurent Vivier review comment and change the subject.
>- Patch2: Use extract16() instead of delete bit operation statement.
>- Patch3: Add Laurent Vivier review comment.
>
>Chen Qun (3):
>  scsi/esp-pci: add g_assert() for fix clang analyzer warning in
>    esp_pci_io_write()
>  display/blizzard: use extract16() for fix clang analyzer warning in
>    blizzard_draw_line16_32()
>  timer/exynos4210_mct: Remove redundant statement in
>    exynos4210_mct_write()
>
> hw/display/blizzard.c     | 10 ++++------
> hw/scsi/esp-pci.c         |  1 +
> hw/timer/exynos4210_mct.c |  4 ----
> 3 files changed, 5 insertions(+), 10 deletions(-)
>
>--
>2.23.0
>

Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Posted by Laurent Vivier 6 days ago
Le 03/04/2020 à 09:51, Chenqun (kuhn) a écrit :
> Ping!
> 
> This series has been reviewed.  Could someone please pick this up (e.g. qemu-trivial?)?

As we are in hard feature freeze now and this is not critical bug fixes
I'm going to queue them for 5.1 except if you have good arguments to
have them in 5.0.

Thanks,
Laurent

>> -----Original Message-----
>> From: Chenqun (kuhn)
>> Sent: Wednesday, March 25, 2020 10:59 AM
>> To: qemu-devel@nongnu.org; qemu-trivial@nongnu.org
>> Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>; laurent@vivier.eu;
>> philmd@redhat.com; Chenqun (kuhn) <kuhn.chenqun@huawei.com>
>> Subject: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static
>> code analyzer
>>
>> v1->v2:
>> - Patch1: Add John Snow review comment.
>> - Patch9: Move the 'dst_type' declaration to while() statement.
>> - Patch12: Add Philippe Mathieu-Daud茅 review comment.
>> - Patch13: Move the 'set' declaration to the for() statement.
>>
>> v2->v3:
>> - Patch1: Add Kevin Wolf review comment.
>> - Patch2: Keep the 'flags' then use it(Base on Kevin's comments).
>> - Patch3: Add Kevin Wolf review comment.
>> - Patch9: Add Francisco Iglesias and Alistair Francis review comment.
>> - Patch10: Juan Quintela has added it to the queue and delete it.
>> - Patch12->Patch11: Add Philippe Mathieu-Daud茅 review comment.
>> - Patch13->Patch12: Add Philippe Mathieu-Daud茅 review comment.
>>
>> v3->v4:
>> - Deleted the patches that have been merged in the v3.
>> - Modify "scsi/esp-pci" Patch, use g_assert with variable size.
>>
>> v4->v5:
>> - Patch1: Add Laurent Vivier review comment and change the subject.
>> - Patch2: Use extract16() instead of delete bit operation statement.
>> - Patch3: Add Laurent Vivier review comment.
>>
>> Chen Qun (3):
>>  scsi/esp-pci: add g_assert() for fix clang analyzer warning in
>>    esp_pci_io_write()
>>  display/blizzard: use extract16() for fix clang analyzer warning in
>>    blizzard_draw_line16_32()
>>  timer/exynos4210_mct: Remove redundant statement in
>>    exynos4210_mct_write()
>>
>> hw/display/blizzard.c     | 10 ++++------
>> hw/scsi/esp-pci.c         |  1 +
>> hw/timer/exynos4210_mct.c |  4 ----
>> 3 files changed, 5 insertions(+), 10 deletions(-)
>>
>> --
>> 2.23.0
>>
> 


RE: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Posted by Chenqun (kuhn) 6 days ago
>-----Original Message-----
>From: Laurent Vivier [mailto:laurent@vivier.eu]
>Sent: Friday, April 3, 2020 4:04 PM
>To: Chenqun (kuhn) <kuhn.chenqun@huawei.com>; qemu-devel@nongnu.org;
>qemu-trivial@nongnu.org
>Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>; philmd@redhat.com
>Subject: Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang
>static code analyzer
>
>Le 03/04/2020 à 09:51, Chenqun (kuhn) a écrit :
>> Ping!
>>
>> This series has been reviewed.  Could someone please pick this up (e.g. qemu-
>trivial?)?
>
>As we are in hard feature freeze now and this is not critical bug fixes I'm going
>to queue them for 5.1 except if you have good arguments to have them in 5.0.
>
OK,  I get it. 
It is important to ensure a stable version!

Thanks.
>>> -----Original Message-----
>>> From: Chenqun (kuhn)
>>> Sent: Wednesday, March 25, 2020 10:59 AM
>>> To: qemu-devel@nongnu.org; qemu-trivial@nongnu.org
>>> Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>;
>>> laurent@vivier.eu; philmd@redhat.com; Chenqun (kuhn)
>>> <kuhn.chenqun@huawei.com>
>>> Subject: [PATCH v5 0/3] redundant code: Fix warnings reported by
>>> Clang static code analyzer
>>>
>>> v1->v2:
>>> - Patch1: Add John Snow review comment.
>>> - Patch9: Move the 'dst_type' declaration to while() statement.
>>> - Patch12: Add Philippe Mathieu-Daud茅 review comment.
>>> - Patch13: Move the 'set' declaration to the for() statement.
>>>
>>> v2->v3:
>>> - Patch1: Add Kevin Wolf review comment.
>>> - Patch2: Keep the 'flags' then use it(Base on Kevin's comments).
>>> - Patch3: Add Kevin Wolf review comment.
>>> - Patch9: Add Francisco Iglesias and Alistair Francis review comment.
>>> - Patch10: Juan Quintela has added it to the queue and delete it.
>>> - Patch12->Patch11: Add Philippe Mathieu-Daud茅 review comment.
>>> - Patch13->Patch12: Add Philippe Mathieu-Daud茅 review comment.
>>>
>>> v3->v4:
>>> - Deleted the patches that have been merged in the v3.
>>> - Modify "scsi/esp-pci" Patch, use g_assert with variable size.
>>>
>>> v4->v5:
>>> - Patch1: Add Laurent Vivier review comment and change the subject.
>>> - Patch2: Use extract16() instead of delete bit operation statement.
>>> - Patch3: Add Laurent Vivier review comment.
>>>
>>> Chen Qun (3):
>>>  scsi/esp-pci: add g_assert() for fix clang analyzer warning in
>>>    esp_pci_io_write()
>>>  display/blizzard: use extract16() for fix clang analyzer warning in
>>>    blizzard_draw_line16_32()
>>>  timer/exynos4210_mct: Remove redundant statement in
>>>    exynos4210_mct_write()
>>>
>>> hw/display/blizzard.c     | 10 ++++------
>>> hw/scsi/esp-pci.c         |  1 +
>>> hw/timer/exynos4210_mct.c |  4 ----
>>> 3 files changed, 5 insertions(+), 10 deletions(-)
>>>
>>> --
>>> 2.23.0
>>>
>>

Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Posted by Laurent Vivier 6 days ago
Le 03/04/2020 à 10:10, Chenqun (kuhn) a écrit :
>> -----Original Message-----
>> From: Laurent Vivier [mailto:laurent@vivier.eu]
>> Sent: Friday, April 3, 2020 4:04 PM
>> To: Chenqun (kuhn) <kuhn.chenqun@huawei.com>; qemu-devel@nongnu.org;
>> qemu-trivial@nongnu.org
>> Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>; philmd@redhat.com
>> Subject: Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang
>> static code analyzer
>>
>> Le 03/04/2020 à 09:51, Chenqun (kuhn) a écrit :
>>> Ping!
>>>
>>> This series has been reviewed.  Could someone please pick this up (e.g. qemu-
>> trivial?)?
>>
>> As we are in hard feature freeze now and this is not critical bug fixes I'm going
>> to queue them for 5.1 except if you have good arguments to have them in 5.0.
>>
> OK,  I get it. 
> It is important to ensure a stable version!

Queued to my linux-user-for-5.1 queue.

Thanks,
Laurent

Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Posted by Laurent Vivier 6 days ago
Le 03/04/2020 à 10:22, Laurent Vivier a écrit :
> Le 03/04/2020 à 10:10, Chenqun (kuhn) a écrit :
>>> -----Original Message-----
>>> From: Laurent Vivier [mailto:laurent@vivier.eu]
>>> Sent: Friday, April 3, 2020 4:04 PM
>>> To: Chenqun (kuhn) <kuhn.chenqun@huawei.com>; qemu-devel@nongnu.org;
>>> qemu-trivial@nongnu.org
>>> Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>; philmd@redhat.com
>>> Subject: Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang
>>> static code analyzer
>>>
>>> Le 03/04/2020 à 09:51, Chenqun (kuhn) a écrit :
>>>> Ping!
>>>>
>>>> This series has been reviewed.  Could someone please pick this up (e.g. qemu-
>>> trivial?)?
>>>
>>> As we are in hard feature freeze now and this is not critical bug fixes I'm going
>>> to queue them for 5.1 except if you have good arguments to have them in 5.0.
>>>
>> OK,  I get it. 
>> It is important to ensure a stable version!
> 
> Queued to my linux-user-for-5.1 queue.

I meant trivial-patches-for-5.1

Thanks,
Laurent

RE: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Posted by Chenqun (kuhn) 6 days ago
>-----Original Message-----
>From: Laurent Vivier [mailto:laurent@vivier.eu]
>Sent: Friday, April 3, 2020 4:28 PM
>To: Chenqun (kuhn) <kuhn.chenqun@huawei.com>; qemu-devel@nongnu.org;
>qemu-trivial@nongnu.org
>Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>; philmd@redhat.com
>Subject: Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang
>static code analyzer
>
>Le 03/04/2020 à 10:22, Laurent Vivier a écrit :
>> Le 03/04/2020 à 10:10, Chenqun (kuhn) a écrit :
>>>> -----Original Message-----
>>>> From: Laurent Vivier [mailto:laurent@vivier.eu]
>>>> Sent: Friday, April 3, 2020 4:04 PM
>>>> To: Chenqun (kuhn) <kuhn.chenqun@huawei.com>; qemu-
>devel@nongnu.org;
>>>> qemu-trivial@nongnu.org
>>>> Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>;
>>>> philmd@redhat.com
>>>> Subject: Re: [PATCH v5 0/3] redundant code: Fix warnings reported by
>>>> Clang static code analyzer
>>>>
>>>> Le 03/04/2020 à 09:51, Chenqun (kuhn) a écrit :
>>>>> Ping!
>>>>>
>>>>> This series has been reviewed.  Could someone please pick this up
>>>>> (e.g. qemu-
>>>> trivial?)?
>>>>
>>>> As we are in hard feature freeze now and this is not critical bug
>>>> fixes I'm going to queue them for 5.1 except if you have good arguments to
>have them in 5.0.
>>>>
>>> OK,  I get it.
>>> It is important to ensure a stable version!
>>
>> Queued to my linux-user-for-5.1 queue.
>
>I meant trivial-patches-for-5.1
>
Thanks. Could you add another trivial patch to the queue by the way?
https://lists.gnu.org/archive/html/qemu-devel/2020-03/msg07534.html

Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang static code analyzer

Posted by Laurent Vivier 6 days ago
Le 03/04/2020 à 10:41, Chenqun (kuhn) a écrit :
>> -----Original Message-----
>> From: Laurent Vivier [mailto:laurent@vivier.eu]
>> Sent: Friday, April 3, 2020 4:28 PM
>> To: Chenqun (kuhn) <kuhn.chenqun@huawei.com>; qemu-devel@nongnu.org;
>> qemu-trivial@nongnu.org
>> Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>; philmd@redhat.com
>> Subject: Re: [PATCH v5 0/3] redundant code: Fix warnings reported by Clang
>> static code analyzer
>>
>> Le 03/04/2020 à 10:22, Laurent Vivier a écrit :
>>> Le 03/04/2020 à 10:10, Chenqun (kuhn) a écrit :
>>>>> -----Original Message-----
>>>>> From: Laurent Vivier [mailto:laurent@vivier.eu]
>>>>> Sent: Friday, April 3, 2020 4:04 PM
>>>>> To: Chenqun (kuhn) <kuhn.chenqun@huawei.com>; qemu-
>> devel@nongnu.org;
>>>>> qemu-trivial@nongnu.org
>>>>> Cc: Zhanghailiang <zhang.zhanghailiang@huawei.com>;
>>>>> philmd@redhat.com
>>>>> Subject: Re: [PATCH v5 0/3] redundant code: Fix warnings reported by
>>>>> Clang static code analyzer
>>>>>
>>>>> Le 03/04/2020 à 09:51, Chenqun (kuhn) a écrit :
>>>>>> Ping!
>>>>>>
>>>>>> This series has been reviewed.  Could someone please pick this up
>>>>>> (e.g. qemu-
>>>>> trivial?)?
>>>>>
>>>>> As we are in hard feature freeze now and this is not critical bug
>>>>> fixes I'm going to queue them for 5.1 except if you have good arguments to
>> have them in 5.0.
>>>>>
>>>> OK,  I get it.
>>>> It is important to ensure a stable version!
>>>
>>> Queued to my linux-user-for-5.1 queue.
>>
>> I meant trivial-patches-for-5.1
>>
> Thanks. Could you add another trivial patch to the queue by the way?
> https://lists.gnu.org/archive/html/qemu-devel/2020-03/msg07534.html

Yes, done.

Thanks,
Laurent