aboutsummaryrefslogtreecommitdiff
path: root/qapi/qmp-registry.c
diff options
context:
space:
mode:
authorDaniele Buono <dbuono@linux.vnet.ibm.com>2020-11-05 17:18:58 -0500
committerThomas Huth <thuth@redhat.com>2020-11-10 08:51:30 +0100
commit074df27f744f0a72f8b33b2fd5a6cdc557f48f7b (patch)
tree1b099dc99e5869f178947f1ef0246b35b7a86355 /qapi/qmp-registry.c
parentad57e2b1f53f507392807e6e2b36c34454b270fa (diff)
downloadqemu-074df27f744f0a72f8b33b2fd5a6cdc557f48f7b.zip
qemu-074df27f744f0a72f8b33b2fd5a6cdc557f48f7b.tar.gz
qemu-074df27f744f0a72f8b33b2fd5a6cdc557f48f7b.tar.bz2
s390x: fix clang 11 warnings in cpu_models.c
There are void * pointers that get casted to enums, in cpu_models.c Such casts can result in a small integer type and are caught as warnings with clang, starting with version 11: Clang 11 finds a bunch of spots in the code that trigger this new warnings: ../qemu-base/target/s390x/cpu_models.c:985:21: error: cast to smaller integer type 'S390Feat' from 'void *' [-Werror,-Wvoid-pointer-to-enum-cast] S390Feat feat = (S390Feat) opaque; ^~~~~~~~~~~~~~~~~ ../qemu-base/target/s390x/cpu_models.c:1002:21: error: cast to smaller integer type 'S390Feat' from 'void *' [-Werror,-Wvoid-pointer-to-enum-cast] S390Feat feat = (S390Feat) opaque; ^~~~~~~~~~~~~~~~~ ../qemu-base/target/s390x/cpu_models.c:1036:27: error: cast to smaller integer type 'S390FeatGroup' from 'void *' [-Werror,-Wvoid-pointer-to-enum-cast] S390FeatGroup group = (S390FeatGroup) opaque; ^~~~~~~~~~~~~~~~~~~~~~ ../qemu-base/target/s390x/cpu_models.c:1057:27: error: cast to smaller integer type 'S390FeatGroup' from 'void *' [-Werror,-Wvoid-pointer-to-enum-cast] S390FeatGroup group = (S390FeatGroup) opaque; ^~~~~~~~~~~~~~~~~~~~~~ 4 errors generated. Avoid this warning by casting the pointer to uintptr_t first. Signed-off-by: Daniele Buono <dbuono@linux.vnet.ibm.com> Message-Id: <20201105221905.1350-3-dbuono@linux.vnet.ibm.com> Acked-by: Cornelia Huck <cohuck@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
Diffstat (limited to 'qapi/qmp-registry.c')
0 files changed, 0 insertions, 0 deletions