From 3fb2111fc9bb9c73bae81c6696bcf333690147b0 Mon Sep 17 00:00:00 2001 From: Marc-André Lureau Date: Wed, 7 Jun 2017 20:36:09 +0400 Subject: qdev: avoid type casts between signed and unsigned MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Modify the unsigned type for various properties to use QNUM_U64, to avoid type casts. There are a few empty lines added to improve code reading/style. Signed-off-by: Marc-André Lureau Message-Id: <20170607163635.17635-18-marcandre.lureau@redhat.com> Reviewed-by: Markus Armbruster [Change to set_default_value_enum() dropped] Signed-off-by: Markus Armbruster --- include/hw/qdev-core.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/hw/qdev-core.h') diff --git a/include/hw/qdev-core.h b/include/hw/qdev-core.h index 784971b8d8..9d7c1c0e9b 100644 --- a/include/hw/qdev-core.h +++ b/include/hw/qdev-core.h @@ -228,6 +228,7 @@ struct Property { uint8_t bitnr; union { int64_t i; + uint64_t u; } defval; int arrayoffset; PropertyInfo *arrayinfo; -- cgit 1.4.1