Skip to content

Various compiler warning fixes for libvhost-user

Marcel Holtmann qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest7 patches 4 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7libvhost-user: Provide _GNU_SOURCE when compiling outside of QEMUsubprojects/libvhost-user/libvhost-user.c+4 -00 replies
2/7libvhost-user: Replace typeof with __typeof__subprojects/libvhost-user/libvhost-user.c+2 -20 replies
3/7libvhost-user: Cast rc variable to avoid compiler warningsubprojects/libvhost-user/libvhost-user.c+1 -10 replies
4/7libvhost-user: Use unsigned int i for some for-loop iterationssubprojects/libvhost-user/libvhost-user.c+7 -70 replies
5/7libvhost-user: Declare uffdio_register early to make it C90 compliantsubprojects/libvhost-user/libvhost-user.c+3 -10 replies
6/7libvhost-user: Change dev->postcopy_ufd assignment to make it C90 compliantsubprojects/libvhost-user/libvhost-user.c+2 -10 replies
7/7libvhost-user: Switch to unsigned int for inuse field in struct VuVirtqsubprojects/libvhost-user/libvhost-user.h+1 -14 replies

Reviews trailers per patch

1 of 7 patches has a Reviewed-by or Acked-by.

PatchPhilippe Mathieu-Daudé
1/7
2/7
3/7
4/7
5/7
6/7
7/7R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/7] Various compiler warning fixes for libvhost-user

The libvhost-user library is also useful for external usage outside of QEMU and thus it would be nice if the two files libvhost-user.[ch] could be just copied and used. However due to different compiler settings, a lot of manual fixups are needed. This is the first attempt at some obvious fixes that can be done without any harm to the code and its readabilty.

Marcel Holtmann (7):
libvhost-user: Provide _GNU_SOURCE when compiling outside of QEMU
libvhost-user: Replace typeof with __typeof__
libvhost-user: Cast rc variable to avoid compiler warning
libvhost-user: Use unsigned int i for some for-loop iterations
libvhost-user: Declare uffdio_register early to make it C90 compliant
libvhost-user: Change dev->postcopy_ufd assignment to make it C90 compliant
libvhost-user: Switch to unsigned int for inuse field in struct VuVirtq

 subprojects/libvhost-user/libvhost-user.c | 31 ++++++++++++++---------
 subprojects/libvhost-user/libvhost-user.h |  2 +-
 2 files changed, 20 insertions(+), 13 deletions(-)
Signature · 1 line
2.38.1