All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nir Muchtar <nirm-smomgflXvOZWk0Htik3J/w@public.gmane.org>
To: rolandd-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org
Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	monis-smomgflXvOZWk0Htik3J/w@public.gmane.org,
	ogerlitz-smomgflXvOZWk0Htik3J/w@public.gmane.org,
	nirm-smomgflXvOZWk0Htik3J/w@public.gmane.org
Subject: [PATCH V3 3/6] IB Core Run Netlink
Date: Mon, 13 Dec 2010 18:22:47 +0200	[thread overview]
Message-ID: <1292257370-24391-4-git-send-email-nirm@voltaire.com> (raw)
In-Reply-To: <1292257370-24391-1-git-send-email-nirm-smomgflXvOZWk0Htik3J/w@public.gmane.org>

Include and initialize IB netlink from IB core.

Signed-off-by: Nir Muchtar <nirm-smomgflXvOZWk0Htik3J/w@public.gmane.org>
---
 drivers/infiniband/core/Makefile |    2 +-
 drivers/infiniband/core/device.c |   11 +++++++++++
 2 files changed, 12 insertions(+), 1 deletions(-)

diff --git a/drivers/infiniband/core/Makefile b/drivers/infiniband/core/Makefile
index cb1ab3e..c8bbaef 100644
--- a/drivers/infiniband/core/Makefile
+++ b/drivers/infiniband/core/Makefile
@@ -8,7 +8,7 @@ obj-$(CONFIG_INFINIBAND_USER_ACCESS) +=	ib_uverbs.o ib_ucm.o \
 					$(user_access-y)
 
 ib_core-y :=			packer.o ud_header.o verbs.o sysfs.o \
-				device.o fmr_pool.o cache.o
+				device.o fmr_pool.o cache.o netlink.o
 ib_core-$(CONFIG_INFINIBAND_USER_MEM) += umem.o
 
 ib_mad-y :=			mad.o smi.o agent.o mad_rmpp.o
diff --git a/drivers/infiniband/core/device.c b/drivers/infiniband/core/device.c
index 6e06e37..3229102 100644
--- a/drivers/infiniband/core/device.c
+++ b/drivers/infiniband/core/device.c
@@ -40,6 +40,8 @@
 #include <linux/mutex.h>
 #include <linux/workqueue.h>
 
+#include <net/ib_netlink.h>
+
 #include "core_priv.h"
 
 MODULE_AUTHOR("Roland Dreier");
@@ -730,8 +732,16 @@ static int __init ib_core_init(void)
 		goto err_sysfs;
 	}
 
+	ret = ibnl_init();
+	if (ret) {
+		printk(KERN_WARNING "Couldn't init IB netlink interface\n");
+		goto err_cache;
+	}
+
 	return 0;
 
+err_cache:
+	ib_cache_cleanup();
 err_sysfs:
 	ib_sysfs_cleanup();
 err:
@@ -740,6 +750,7 @@ err:
 
 static void __exit ib_core_cleanup(void)
 {
+	ibnl_cleanup();
 	ib_cache_cleanup();
 	ib_sysfs_cleanup();
 	/* Make sure that any pending umem accounting work is done. */
-- 
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2010-12-13 16:22 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-13 16:22 [PATCH V3 0/6] IB Netlink Interface and RDMA CM exports Nir Muchtar
     [not found] ` <1292257370-24391-1-git-send-email-nirm-smomgflXvOZWk0Htik3J/w@public.gmane.org>
2010-12-13 16:22   ` [PATCH V3 1/6] IB Netlink Infrastructure Nir Muchtar
     [not found]     ` <1292257370-24391-2-git-send-email-nirm-smomgflXvOZWk0Htik3J/w@public.gmane.org>
2010-12-14 18:34       ` Jason Gunthorpe
     [not found]         ` <20101214183401.GC2506-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2010-12-19 14:34           ` Nir Muchtar
2010-12-13 16:22   ` [PATCH V3 2/6] IB Core: Error Handler Nir Muchtar
2010-12-13 16:22   ` Nir Muchtar [this message]
2010-12-13 16:22   ` [PATCH V3 4/6] RDMA CM: Export State Enum Nir Muchtar
2010-12-13 16:22   ` [PATCH V3 5/6] RDMA CM: Save Owning PID Nir Muchtar
     [not found]     ` <1292257370-24391-6-git-send-email-nirm-smomgflXvOZWk0Htik3J/w@public.gmane.org>
2010-12-14 18:34       ` Jason Gunthorpe
     [not found]         ` <20101214183458.GD2506-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2010-12-19 14:36           ` Nir Muchtar
2010-12-20 21:54             ` Jason Gunthorpe
     [not found]               ` <20101220215433.GB12090-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2010-12-21 15:05                 ` Nir Muchtar
2010-12-21 18:10                   ` Jason Gunthorpe
2010-12-21 19:43                     ` Nir Muchtar
2010-12-21 20:33                       ` Nir Muchtar
     [not found]                       ` <7E95F01E94AB484F83061FCFA35B39F8794E3F-QfUkFaTmzUSUvQqKE/ONIwC/G2K4zDHf@public.gmane.org>
2010-12-21 20:36                         ` Jason Gunthorpe
     [not found]                           ` <20101221203627.GE12090-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2010-12-22 16:03                             ` Nir Muchtar
2010-12-22 22:10                               ` Jason Gunthorpe
     [not found]                     ` <20101221181043.GD12090-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2010-12-23 12:21                       ` Or Gerlitz
2010-12-13 16:22   ` [PATCH V3 6/6] RDMA CM: Netlink Client Nir Muchtar
     [not found]     ` <1292257370-24391-7-git-send-email-nirm-smomgflXvOZWk0Htik3J/w@public.gmane.org>
2010-12-14 18:45       ` Jason Gunthorpe
     [not found]         ` <20101214184514.GE2506-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2010-12-19 14:47           ` Nir Muchtar
2010-12-20  7:24             ` Or Gerlitz
2010-12-20 19:16             ` Hefty, Sean
2010-12-20 21:52             ` Jason Gunthorpe
2010-12-14 18:27   ` [PATCH V3 0/6] IB Netlink Interface and RDMA CM exports Jason Gunthorpe
     [not found]     ` <20101214182746.GB2506-ePGOBjL8dl3ta4EC/59zMFaTQe2KTcn/@public.gmane.org>
2010-12-19 14:30       ` Nir Muchtar
2010-12-20 21:55         ` Jason Gunthorpe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1292257370-24391-4-git-send-email-nirm@voltaire.com \
    --to=nirm-smomgflxvozwk0htik3j/w@public.gmane.org \
    --cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=monis-smomgflXvOZWk0Htik3J/w@public.gmane.org \
    --cc=ogerlitz-smomgflXvOZWk0Htik3J/w@public.gmane.org \
    --cc=rolandd-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.