[PATCH for-6.1? v2 0/9] Fixes for clang-13

Richard Henderson posted 9 patches 4 years, 6 months ago
Test checkpatch passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20210725122416.1391332-1-richard.henderson@linaro.org
Maintainers: Eric Blake <eblake@redhat.com>, Laurent Vivier <laurent@vivier.eu>, Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>, David Gibson <david@gibson.dropbear.id.au>, Greg Kurz <groug@kaod.org>, Jason Wang <jasowang@redhat.com>, "Cédric Le Goater" <clg@kaod.org>
accel/tcg/cpu-exec.c   | 10 ++--------
hw/audio/adlib.c       |  3 +--
hw/pci-host/pnv_phb4.c |  2 +-
hw/ppc/spapr_events.c  |  5 -----
linux-user/syscall.c   |  3 ---
nbd/server.c           |  3 ++-
net/checksum.c         |  4 +---
tests/unit/test-iov.c  |  5 +----
util/selfmap.c         | 29 +++++++++++++++++------------
9 files changed, 25 insertions(+), 39 deletions(-)
[PATCH for-6.1? v2 0/9] Fixes for clang-13
Posted by Richard Henderson 4 years, 6 months ago
These are all "variable set but not used" Werrors when building
with clang master.

Patch 1 is clearly a clang bug, not considering the side-effects
of g_autofree, but the rest are legitimate.


r~


Richard Henderson (9):
  nbd/server: Mark variable unused in nbd_negotiate_meta_queries
  accel/tcg: Remove unused variable in cpu_exec
  util/selfmap: Discard mapping on error
  net/checksum: Remove unused variable in net_checksum_add_iov
  hw/audio/adlib: Remove unused variable in adlib_callback
  hw/ppc/spapr_events: Remove unused variable from check_exception
  hw/pci-hist/pnv_phb4: Fix typo in pnv_phb4_ioda_write
  linux-user/syscall: Remove unused variable from execve
  tests/unit: Remove unused variable from test_io

 accel/tcg/cpu-exec.c   | 10 ++--------
 hw/audio/adlib.c       |  3 +--
 hw/pci-host/pnv_phb4.c |  2 +-
 hw/ppc/spapr_events.c  |  5 -----
 linux-user/syscall.c   |  3 ---
 nbd/server.c           |  3 ++-
 net/checksum.c         |  4 +---
 tests/unit/test-iov.c  |  5 +----
 util/selfmap.c         | 29 +++++++++++++++++------------
 9 files changed, 25 insertions(+), 39 deletions(-)

-- 
2.25.1


Re: [PATCH for-6.1? v2 0/9] Fixes for clang-13
Posted by Richard Henderson 4 years, 6 months ago
On 7/25/21 2:24 AM, Richard Henderson wrote:
> 
> Richard Henderson (9):
>    nbd/server: Mark variable unused in nbd_negotiate_meta_queries
>    accel/tcg: Remove unused variable in cpu_exec
>    util/selfmap: Discard mapping on error
>    net/checksum: Remove unused variable in net_checksum_add_iov
>    hw/audio/adlib: Remove unused variable in adlib_callback
>    hw/ppc/spapr_events: Remove unused variable from check_exception
>    hw/pci-hist/pnv_phb4: Fix typo in pnv_phb4_ioda_write
>    linux-user/syscall: Remove unused variable from execve
>    tests/unit: Remove unused variable from test_io

Queued for 6.1.
Thanks for the reviews, all.

r~