]> git.droids-corp.org - dpdk.git/commitdiff
lib: work around large enum values
authorAdrien Mazarguil <adrien.mazarguil@6wind.com>
Thu, 8 Sep 2016 12:25:03 +0000 (14:25 +0200)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Tue, 13 Sep 2016 13:35:28 +0000 (15:35 +0200)
Exported header files used by applications should allow the strictest
compiler flags. Language extensions used in many places must be explicitly
marked or removed to avoid warnings and compilation failures.

This commit prevents the following errors:

 error: ISO C restricts enumerator values to range of `int'

Signed-off-by: Adrien Mazarguil <adrien.mazarguil@6wind.com>
lib/librte_eal/common/include/rte_memory.h

index d9e8c21340ec2b88c800bcb0dd0492372147885f..12e0ebb077ad8d9ddb4ee198b32b5e228fb8aaf9 100644 (file)
@@ -54,6 +54,7 @@ extern "C" {
 
 #include <rte_common.h>
 
+__extension__
 enum rte_page_sizes {
        RTE_PGSIZE_4K    = 1ULL << 12,
        RTE_PGSIZE_64K   = 1ULL << 16,