diff --git a/iscsi-scst/Makefile b/iscsi-scst/Makefile index 2f62dbca8..4b5c94e3b 100644 --- a/iscsi-scst/Makefile +++ b/iscsi-scst/Makefile @@ -89,8 +89,7 @@ ifeq ($(OFED_FLAVOR),MOFED) OFED_DIR:=/usr/src/ofa_kernel/default OFED_CFLAGS:= -I$(OFED_DIR)/include \ -I$(OFED_DIR)/include/uapi \ - -include $(OFED_DIR)/include/linux/compat-2.6.h \ - -DMOFED_MAJOR=$(shell echo $(OFED_VERS) | cut -f1 -d.) + -include $(OFED_DIR)/include/linux/compat-2.6.h ISER_SYMVERS:="$(ISER_SYMVERS) $(OFED_DIR)/Module.symvers" else # Whether or not the OFED kernel-ib-devel RPM has been installed. diff --git a/scripts/specialize-patch b/scripts/specialize-patch index 4d7f8c241..bf4945a43 100755 --- a/scripts/specialize-patch +++ b/scripts/specialize-patch @@ -168,17 +168,6 @@ function evaluate(stmnt, pattern, arg, op, result) { "(\\1) * 256 + (\\2)", "g", stmnt) } - if (MOFED_MAJOR == "") - { - gsub("defined\\(MOFED_MAJOR\\)", "0", stmnt) - gsub("MOFED_MAJOR", "", stmnt) - } - else - { - gsub("defined\\(MOFED_MAJOR\\)", "1", stmnt) - gsub("MOFED_MAJOR", MOFED_MAJOR, stmnt) - } - if (SCSI_EXEC_REQ_FIFO_DEFINED != "") { gsub("defined[[:blank:]]+SCSI_EXEC_REQ_FIFO_DEFINED", @@ -361,7 +350,6 @@ function handle_if(evaluated) || $0 ~ "INSIDE_KERNEL_TREE" \ || $0 ~ "MAD_HANDLER_TAKES_SEND_BUF" \ || $0 ~ "CONFIG_SCST_STRICT_SERIALIZING" \ - || $0 ~ "MOFED_MAJOR" \ || $0 ~ "RDMA_CREATE_ID_TAKES_NET_ARG" \ || $0 ~ "REGISTER_MAD_AGENT_HAS_FLAGS_ARG" \ || $0 ~ "RHEL_MAJOR" \ diff --git a/srpt/Makefile b/srpt/Makefile index 2c3c4750e..503e56a77 100644 --- a/srpt/Makefile +++ b/srpt/Makefile @@ -74,8 +74,6 @@ ifeq ($(OFED_FLAVOR),MOFED) OFED_KERNEL_DIR:=/usr/src/ofa_kernel/default OFED_VERS=$(shell rpm -q --qf '%{version}\n' mlnx-ofa_kernel-devel 2>/dev/null | grep -v ' '; dpkg-query -W --showformat='$${Version}\n' mlnx-ofed-kernel-dkms 2>/dev/null) OFED_CFLAGS:=-I$(OFED_KERNEL_DIR)/include -include "linux/compat-2.6.h" -OFED_CFLAGS+=-DMOFED_MAJOR=$(shell echo "$(OFED_VERS)" | sed 's/\([0-9]\+\)[^0-9]\+\([0-9]\+\).*/\1/g') -OFED_CFLAGS+=-DMOFED_MINOR=$(shell echo "$(OFED_VERS)" | sed 's/\([0-9]\+\)[^0-9]\+\([0-9]\+\).*/\2/g') else # OFED 1.5 OFED_KERNEL_DIR:=/usr/src/ofa_kernel