iser: fix a warning about container_of being redefined
PATCH 1/1 iser: fix a warning about container_of being redefined
container_of is being defined in list.h and verbs.h differently. To keep tgtd toe use the container_of from list.h as today, Instead of wrapping ifndef which exists in verbs.h I moved the inclusion of verbs to after list.h
Signed-off-by Roi Dayan <[email protected]>
--- usr/iscsi/iser.c | 4 +--- usr/iscsi/iser.h | 3 +++ usr/iscsi/iser_text.c | 2 -- 3 files changed, 4 insertions(+), 5 deletions(-)
usr/iscsi/iser.c +1 -3
@@ -30,18 +30,16 @@#include <assert.h> #include <netdb.h> #include <sys/epoll.h> -#include <infiniband/verbs.h> -#include <rdma/rdma_cma.h> #include <sys/ipc.h> #include <sys/shm.h> #include "util.h" #include "iscsid.h" #include "target.h" -#include "iser.h" #include "driver.h" #include "scsi.h" #include "work.h" +#include "iser.h" #if defined(HAVE_VALGRIND ) && !defined(NDEBUG )#include <valgrind/memcheck.h>
usr/iscsi/iser.h +3 -0
@@ -25,6 +25,9 @@#include "iscsid.h" +#include <infiniband/verbs.h> +#include <rdma/rdma_cma.h> +extern short control_port;/*
usr/iscsi/iser_text.c +0 -2
@@ -31,8 +31,6 @@#include <assert.h> #include <netdb.h> #include <sys/epoll.h> -#include <infiniband/verbs.h> -#include <rdma/rdma_cma.h> #include "util.h" #include "iscsid.h"
Signature · 1 line
1.7.8.2
FUJITA Tomonori
AppliedQuoted 11 lines · On Thu, 10 Apr 2014 18:40:51 +0300 Roi Dayan <[email protected]> wrote:
container_ofis being defined inlist.handverbs.hdifferently. To keep tgtd toe use thecontainer_offromlist.has today, Instead of wrapping ifndef which exists inverbs.hI moved the inclusion of verbs to afterlist.hSigned-off-by Roi Dayan <[email protected]>--- usr/iscsi/iser.c | 4 +--- usr/iscsi/iser.h | 3 +++ usr/iscsi/iser_text.c | 2 -- 3 files changed, 4 insertions(+), 5 deletions(-)
Applied, thanks.