[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 37/45] virtiofsd: replace _Static_assert with QEMU_BUILD_BUG_ON
From: |
Paolo Bonzini |
Subject: |
[PULL 37/45] virtiofsd: replace _Static_assert with QEMU_BUILD_BUG_ON |
Date: |
Tue, 15 Dec 2020 12:54:37 -0500 |
From: Marc-André Lureau <marcandre.lureau@redhat.com>
This allows to get rid of a check for older GCC version (which was a bit
bogus too since it was falling back on c++ version..)
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Message-Id: <20201210134752.780923-7-marcandre.lureau@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
tools/virtiofsd/fuse_common.h | 11 +----------
1 file changed, 1 insertion(+), 10 deletions(-)
diff --git a/tools/virtiofsd/fuse_common.h b/tools/virtiofsd/fuse_common.h
index 30b18b4966..a090040bb2 100644
--- a/tools/virtiofsd/fuse_common.h
+++ b/tools/virtiofsd/fuse_common.h
@@ -807,15 +807,6 @@ void fuse_remove_signal_handlers(struct fuse_session *se);
*
* On 32bit systems please add -D_FILE_OFFSET_BITS=64 to your compile flags!
*/
-
-#if defined(__GNUC__) && \
- (__GNUC__ > 4 || __GNUC__ == 4 && __GNUC_MINOR__ >= 6) && \
- !defined __cplusplus
-_Static_assert(sizeof(off_t) == 8, "fuse: off_t must be 64bit");
-#else
-struct _fuse_off_t_must_be_64bit_dummy_struct {
- unsigned _fuse_off_t_must_be_64bit:((sizeof(off_t) == 8) ? 1 : -1);
-};
-#endif
+QEMU_BUILD_BUG_ON(sizeof(off_t) != 8);
#endif /* FUSE_COMMON_H_ */
--
2.26.2
- [PULL 32/45] qemu/atomic: Drop special case for unsupported compiler, (continued)
- [PULL 32/45] qemu/atomic: Drop special case for unsupported compiler, Paolo Bonzini, 2020/12/15
- [PULL 35/45] qemu-plugin.h: remove GCC < 4, Paolo Bonzini, 2020/12/15
- [PULL 42/45] linux-user: remove GNUC check, Paolo Bonzini, 2020/12/15
- [PULL 20/45] accel/tcg: Remove deprecated '-tb-size' option, Paolo Bonzini, 2020/12/15
- [PULL 28/45] qemu-option: pass QemuOptsList to opts_accepts_any, Paolo Bonzini, 2020/12/15
- [PULL 24/45] icount: improve exec nocache usage, Paolo Bonzini, 2020/12/15
- [PULL 29/45] vl: rename local variable in configure_accelerators, Paolo Bonzini, 2020/12/15
- [PULL 31/45] hw/core: Restrict 'fw-path-provider.c' to system mode emulation, Paolo Bonzini, 2020/12/15
- [PULL 33/45] accel/tcg: Remove special case for GCC < 4.6, Paolo Bonzini, 2020/12/15
- [PULL 30/45] docs: set CONFDIR when running sphinx, Paolo Bonzini, 2020/12/15
- [PULL 37/45] virtiofsd: replace _Static_assert with QEMU_BUILD_BUG_ON,
Paolo Bonzini <=
- [PULL 34/45] compiler.h: remove GCC < 3 __builtin_expect fallback, Paolo Bonzini, 2020/12/15
- [PULL 39/45] poison: remove GNUC check, Paolo Bonzini, 2020/12/15
- [PULL 38/45] compiler.h: explicit case for Clang printf attribute, Paolo Bonzini, 2020/12/15
- [PULL 41/45] compiler: remove GNUC check, Paolo Bonzini, 2020/12/15
- [PULL 19/45] memory: clamp cached translation in case it points to an MMIO region, Paolo Bonzini, 2020/12/15
- [PULL 44/45] scripts/git.orderfile: Keep files with .inc extension sorted, Paolo Bonzini, 2020/12/15
- [PULL 43/45] compiler.h: remove QEMU_GNUC_PREREQ, Paolo Bonzini, 2020/12/15
- [PULL 40/45] xen: remove GNUC check, Paolo Bonzini, 2020/12/15
- [PULL 45/45] build: -no-pie is no functional linker flag, Paolo Bonzini, 2020/12/15
- Re: [PULL 00/45] Misc patches for 2020-12-15, Peter Maydell, 2020/12/16