From ddea2d2f982276001562f169a3a3556a64cd58ce Mon Sep 17 00:00:00 2001 From: Wu Libin Date: Wed, 18 Jun 2014 20:13:14 +0800 Subject: [PATCH 1/1] LU-5224 lnet: build failed with MLNX_OFED-2.2 Build lustre client can fail on the SLES11 SP3 with MLNX_OFED-2.2 against the kernel-3.0.76-0.11, which will cause the "'pm_qos_req' has incomplete type" error.This patch put "#include " in front of "#include " to solve this problem. This error come with the configure option "--with-o2ib=/usr/src/ofa_kernel/default/", it affect the search path of the compiler, which will search the header files in this directory before the kernel header files directory. This patch change this way because "net/sock.h"(exactly is "linux/netdevice.h") include header file "linux/pm_qos_params.h", the pm_qos_params.h is exist both in ofa_kernel include directory and kernel include directory, so we need to put the linux/compat-2.6.h in front of net/sock.h to solve the compatible problem. Signed-off-by: Wu Libin Change-Id: I98df2a5faaecbd44528d3bd8a7ba796cc1d14cdc Reviewed-on: http://review.whamcloud.com/10749 Tested-by: Maloo Reviewed-by: Dmitry Eremin Tested-by: Jenkins Reviewed-by: Minh Diep Reviewed-by: Oleg Drokin --- lnet/klnds/o2iblnd/o2iblnd.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lnet/klnds/o2iblnd/o2iblnd.h b/lnet/klnds/o2iblnd/o2iblnd.h index 26524f5..71c1c1e 100644 --- a/lnet/klnds/o2iblnd/o2iblnd.h +++ b/lnet/klnds/o2iblnd/o2iblnd.h @@ -63,12 +63,13 @@ #include #endif -#include -#include - #ifdef HAVE_COMPAT_RDMA #include #endif + +#include +#include + #include #include #include -- 1.8.3.1