]> granicus.if.org Git - zfs/commitdiff
Linux 5.0 compat: ASM_BUG macro
authorBrian Behlendorf <behlendorf1@llnl.gov>
Wed, 8 May 2019 17:18:40 +0000 (10:18 -0700)
committerGitHub <noreply@github.com>
Wed, 8 May 2019 17:18:40 +0000 (10:18 -0700)
The 5.0 kernel defines the macro ASM_BUG.  In order to prevent a
conflict and build failure rename ASM_BUG to ZFS_ASM_BUG.  This
is currently only an issue on aarch64 but all instances of
ASM_BUG we're renamed to avoid any future conflict on x86_64.

Reviewed-by: Tomohiro Kusumi <kusumi.tomohiro@gmail.com>
Reviewed-by: Richard Laager <rlaager@wiktel.com>
Reviewed-by: Chris Dunlop <chris@onthe.net.au>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #8725
Issue #8545

module/zfs/vdev_raidz_math_aarch64_neon_common.h
module/zfs/vdev_raidz_math_avx2.c
module/zfs/vdev_raidz_math_avx512bw.c
module/zfs/vdev_raidz_math_ssse3.c

index cb9ff86c10c1b85c6530c678eef50a5a3ab18e01..024917417a5500eee80af48b25f3e0fec972df88 100644 (file)
 #define        _R_23(_0, _1, REG2, REG3, ...) REG2, REG3
 #define        R_23(REG...) _R_23(REG, 1, 2, 3)
 
-#define        ASM_BUG()       ASSERT(0)
+#define        ZFS_ASM_BUG()   ASSERT(0)
 
 #define        OFFSET(ptr, val)        (((unsigned char *)(ptr))+val)
 
@@ -197,7 +197,7 @@ typedef struct v {
                :       "v20", "v21");                                  \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -221,7 +221,7 @@ typedef struct v {
                :       RVR0(r), RVR1(r));                              \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -256,7 +256,7 @@ typedef struct v {
                :       WVR0(r), WVR1(r));                              \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -280,7 +280,7 @@ typedef struct v {
                :       RVR0(r), RVR1(r));                              \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -329,7 +329,7 @@ typedef struct v {
                [SRC1] "Q" (*(OFFSET(src, 16))));                       \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -378,7 +378,7 @@ typedef struct v {
                :       RVR0(r), RVR1(r));                              \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -441,7 +441,7 @@ typedef struct v {
                :       "v18", "v19");                                  \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -512,7 +512,7 @@ typedef struct v {
                :       "v10", "v11", "v12", "v13", "v14", "v15");      \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -527,7 +527,7 @@ typedef struct v {
                _MULx2(c, R_01(r));                                     \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
index 07113a2352ce3cabe92eee1f8a683bcb108222d7..063d29bcd8bf45dd40bc75350bf3a56b2d8ef7b1 100644 (file)
@@ -55,7 +55,7 @@
 #define        _R_23(_0, _1, REG2, REG3, ...) REG2, REG3
 #define        R_23(REG...) _R_23(REG, 1, 2, 3)
 
-#define        ASM_BUG()       ASSERT(0)
+#define        ZFS_ASM_BUG()   ASSERT(0)
 
 extern const uint8_t gf_clmul_mod_lt[4*256][16];
 
@@ -84,7 +84,7 @@ typedef struct v {
                    : : [SRC] "r" (src));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -104,7 +104,7 @@ typedef struct v {
                    "vpxor %" VR1(r) ", %" VR3(r)", %" VR3(r));         \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -126,7 +126,7 @@ typedef struct v {
                    "vmovdqa %" VR1(r) ", %" VR3(r));                   \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -148,7 +148,7 @@ typedef struct v {
                    : : [SRC] "r" (src));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -170,7 +170,7 @@ typedef struct v {
                    : : [DST] "r" (dst));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -201,7 +201,7 @@ typedef struct v {
                    "vpxor    %ymm13,     %" VR1(r)", %" VR1(r));       \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -216,7 +216,7 @@ typedef struct v {
            _MUL2(r);                                                   \
            break;                                                      \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -277,7 +277,7 @@ static const uint8_t __attribute__((aligned(32))) _mul_mask = 0x0F;
                    [lt] "r" (gf_clmul_mod_lt[4*(c)]));                 \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -292,7 +292,7 @@ static const uint8_t __attribute__((aligned(32))) _mul_mask = 0x0F;
                _MULx2(c, R_01(r));                                     \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
index 3d5326b9e6e161aae77b61461d1af7e300f267df..d605653db3f1dd45c6f8d3339c4af87aa54c99b8 100644 (file)
@@ -57,7 +57,7 @@
 #define        _R_23(_0, _1, REG2, REG3, ...) REG2, REG3
 #define        R_23(REG...) _R_23(REG, 1, 2, 3)
 
-#define        ASM_BUG()       ASSERT(0)
+#define        ZFS_ASM_BUG()   ASSERT(0)
 
 extern const uint8_t gf_clmul_mod_lt[4*256][16];
 
@@ -85,7 +85,7 @@ typedef struct v {
                    : : [SRC] "r" (src));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -105,7 +105,7 @@ typedef struct v {
                    "vpxorq %" VR1(r) ", %" VR3(r)", %" VR3(r));        \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -127,7 +127,7 @@ typedef struct v {
                    "vmovdqa64 %" VR1(r) ", %" VR3(r));                 \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -149,7 +149,7 @@ typedef struct v {
                    : : [SRC] "r" (src));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -171,7 +171,7 @@ typedef struct v {
                    : : [DST] "r" (dst));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -197,7 +197,7 @@ typedef struct v {
                    "vmovdqu8   %zmm13,     %" VR1(r) "{%k2}");         \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -212,7 +212,7 @@ typedef struct v {
            _MUL2(r);                                                   \
            break;                                                      \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -273,7 +273,7 @@ static const uint8_t __attribute__((aligned(64))) _mul_mask = 0x0F;
                    [lt] "r" (gf_clmul_mod_lt[4*(c)]));                 \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -288,7 +288,7 @@ static const uint8_t __attribute__((aligned(64))) _mul_mask = 0x0F;
                _MULx2(c, R_01(r));                                     \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
index a015baab2d83114da6ec4029a43b1ffcdc37e94c..047a48d544f1fed804da46baac3a44d29258c918 100644 (file)
@@ -56,7 +56,7 @@
 #define        _R_23(_0, _1, REG2, REG3, ...) REG2, REG3
 #define        R_23(REG...) _R_23(REG, 1, 2, 3)
 
-#define        ASM_BUG()       ASSERT(0)
+#define        ZFS_ASM_BUG()   ASSERT(0)
 
 const uint8_t gf_clmul_mod_lt[4*256][16];
 
@@ -85,7 +85,7 @@ typedef struct v {
                    : : [SRC] "r" (src));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -105,7 +105,7 @@ typedef struct v {
                    "pxor %" VR1(r) ", %" VR3(r));                      \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -127,7 +127,7 @@ typedef struct v {
                    "movdqa %" VR1(r) ", %" VR3(r));                    \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -149,7 +149,7 @@ typedef struct v {
                    : : [SRC] "r" (src));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -171,7 +171,7 @@ typedef struct v {
                    : : [DST] "r" (dst));                               \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -200,7 +200,7 @@ typedef struct v {
                    "pxor    %xmm13,      %" VR1(r));                   \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -215,7 +215,7 @@ typedef struct v {
                _MUL2_x2(r);                                            \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -284,7 +284,7 @@ typedef struct v {
                    [lt] "r" (gf_clmul_mod_lt[4*(c)]));                 \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }
 
@@ -299,7 +299,7 @@ typedef struct v {
                _MULx2(c, R_01(r));                                     \
                break;                                                  \
        default:                                                        \
-               ASM_BUG();                                              \
+               ZFS_ASM_BUG();                                          \
        }                                                               \
 }