Commit 2755fbdf authored by paul luse's avatar paul luse Committed by Tomasz Zawadzki
Browse files

scripts: fix configure & autotest scripts that check for Intel proc



Used to determine whether IDXD isto be  configured, previous check
did not work on FreeBSD, only Linux.

Signed-off-by: default avatarpaul luse <paul.e.luse@intel.com>
Change-Id: I70148ee2f0fffc83c2b89d2de6e81193b9357d3f
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/2060


Community-CI: Mellanox Build Bot
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarAleksey Marchuk <alexeymar@mellanox.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: default avatarDarek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
parent 40e5d4a0
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -473,8 +473,13 @@ fi

# IDXD uses Intel specific instructions.
if [[ "${CONFIG[IDXD]}" = "y" ]]; then
	if [ $(uname -s) == "FreeBSD" ]; then
		intel="hw.model: Intel"
		cpu_vendor=$(sysctl -a | grep hw.model | cut -c 1-15)
	else
		intel="GenuineIntel"
		cpu_vendor=$(grep -i 'vendor' /proc/cpuinfo  --max-count=1)
	fi
	if [[ "$cpu_vendor" != *"$intel"* ]]; then
		echo "ERROR: IDXD cannot be used due to CPU incompatiblity."
		exit 1
+7 −2
Original line number Diff line number Diff line
@@ -221,8 +221,13 @@ function get_config_params() {
		config_params+=' --with-rdma'
	fi

        if [ $(uname -s) == "FreeBSD" ]; then
                intel="hw.model: Intel"
                cpu_vendor=$(sysctl -a | grep hw.model | cut -c 1-15)
        else
                intel="GenuineIntel"
                cpu_vendor=$(grep -i 'vendor' /proc/cpuinfo  --max-count=1)
        fi
	if [[ "$cpu_vendor" != *"$intel"* ]]; then
		config_params+=" --without-idxd"
	else