Whamcloud - gitweb
LU-16116 build: Configure tests for rhltable, bitmap_alloc...
authorShaun Tancheff <shaun.tancheff@hpe.com>
Tue, 31 Jan 2023 19:39:47 +0000 (11:39 -0800)
committerAndreas Dilger <adilger@whamcloud.com>
Thu, 16 Feb 2023 21:17:13 +0000 (21:17 +0000)
rhel8.6 with kernel 5.18 breaks a couple of compile tests

struct rhltable test fails with:
... error: ‘hlt’ is used uninitialized in this function
    [-Werror=uninitialized]

rdma_wr() test failes with:
... error: assignment discards ‘const’ qualifier from pointer
    target type [-Werror=discarded-qualifiers]
   wr = rdma_wr(NULL);

Lustre-change: https://review.whamcloud.com/48361
Lustre-commit: 009faf132dc47dcfb604b95c93211da7d2c644e2

Test-Parameters: trivial
HPE-bug-id: LUS-11191
Signed-off-by: Shaun Tancheff <shaun.tancheff@hpe.com>
Change-Id: Ib2b1d223ac809cea157158fe35fd2535b04367df
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Jian Yu <yujian@whamcloud.com>
Reviewed-by: Petros Koutoupis <petros.koutoupis@hpe.com>
Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/49848
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
libcfs/autoconf/lustre-libcfs.m4
lnet/autoconf/lustre-lnet.m4

index 420da3e..fbae889 100644 (file)
@@ -704,7 +704,7 @@ LB_CHECK_COMPILE([does 'struct rhltable' exist],
 rhtable, [
        #include <linux/rhashtable.h>
 ],[
-       struct rhltable *hlt;
+       struct rhltable *hlt = NULL;
 
        rhltable_destroy(hlt);
 ],[
index 13a70e9..fd6cb5d 100644 (file)
@@ -425,7 +425,7 @@ AS_IF([test $ENABLEO2IB != "no"], [
                #endif
                #include <rdma/ib_verbs.h>
        ],[
-               struct ib_rdma_wr *wr __attribute__ ((unused));
+               const struct ib_rdma_wr *wr __attribute__ ((unused));
 
                wr = rdma_wr(NULL);
        ],[