From 808edee78454ee2f222c5774567cf6a7d4bd8408 Mon Sep 17 00:00:00 2001 From: Shaun Tancheff Date: Wed, 28 Feb 2024 23:00:26 +0700 Subject: [PATCH] LU-17579 build: drop SUSE in-kernel ofed special handling SUSE special case handling for mofed does not apply to in-kernel ofed build. Drop the complicated search and filter looking for Module.symvers Test-Parameters: trivial Fixes: 8b1d2a72f1 ("LU-16967 build: Add in-kernel-ko2iblnd driver") Signed-off-by: Shaun Tancheff Change-Id: I90c3de9020a26bdbc12c0ca859ada722b7c73c94 Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/54176 Tested-by: jenkins Tested-by: Maloo Reviewed-by: Petros Koutoupis Reviewed-by: Caleb Carlson Reviewed-by: Oleg Drokin --- lnet/autoconf/lustre-lnet.m4 | 24 +++++------------------- 1 file changed, 5 insertions(+), 19 deletions(-) diff --git a/lnet/autoconf/lustre-lnet.m4 b/lnet/autoconf/lustre-lnet.m4 index 180f175..8595211 100644 --- a/lnet/autoconf/lustre-lnet.m4 +++ b/lnet/autoconf/lustre-lnet.m4 @@ -310,29 +310,15 @@ Auto detection of external O2IB failed. Build of external o2ib disabled.]) fi fi - # we suspect that the found in-kernel OFED source+headers are good - # the above compile test *could* be repeated with in-kernel paths ... + # we expect that the found in-kernel OFED source+headers are good INT_O2IB_SYMBOLS="" CHECK_SYMBOLS="" - if test -f $INT_O2IBPATH/Module.symvers; then - CHECK_SYMBOLS=$INT_O2IBPATH/Module.symvers - elif test "x$SUSE_KERNEL" = "xyes"; then - CHECK_SYMBOLS=$(find ${INT_O2IBPATH}* -name Module.symvers -printf "%p ") - # Select only the current 'flavor' if there is more than 1 - NUM_AVAIL=$(find ${INT_O2IBPATH}* -name Module.symvers | wc -l) - if test ${NUM_AVAIL} -gt 1; then - PREFER=$(basename ${LINUX_OBJ}) - for F in $(find ${O2IBPATH}-obj -name Module.symvers) - do - maybe=$(echo $F | grep "/${PREFER}") - if test "x$maybe" != "x"; then - CHECK_SYMBOLS=$F - fi - done - fi - elif test -f $LINUX_OBJ/Module.symvers; then + if test -f $LINUX_OBJ/Module.symvers; then # Debian symvers is in the arch tree + # SUSE symvers is in the OBJ tree [KVER-obj///] CHECK_SYMBOLS=$LINUX_OBJ/Module.symvers + elif test -f $INT_O2IBPATH/Module.symvers; then + CHECK_SYMBOLS=$INT_O2IBPATH/Module.symvers fi if test -n "$CHECK_SYMBOLS"; then -- 1.8.3.1