Skip to contentSkip to conversation

infiniband: adding __init/__exit macros to addr.c and cma.c

PATCH In review Peter Hüwe 4 participants 7 messages Jun 11, 2009 – Jun 23, 2009

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 infiniband: adding __init/__exit macros to addr.c and cma.c

From: Peter Huewe <[email protected]>

Trivial patch which adds the __init and __exit macros to the module_init / module_exit functions from drivers/infiniband/core/addr.c and cma.c linux version 2.6.30

---

drivers/infiniband/core/addr.c +2 -2
index ce511d8..5be1bd4 100644
@@ -514,7 +514,7 @@ static struct notifier_block nb = {
 	.notifier_call = netevent_callback
 };
 
-static int addr_init(void)
+static int __init addr_init(void)
 {
 	addr_wq = create_singlethread_workqueue("ib_addr");
 	if (!addr_wq)
@@ -524,7 +524,7 @@ static int addr_init(void)
 	return 0;
 }
 
-static void addr_cleanup(void)
+static void __exit addr_cleanup(void)
 {
 	unregister_netevent_notifier(&nb);
 	destroy_workqueue(addr_wq);
drivers/infiniband/core/cma.c +2 -2
index 851de83..0753178 100644
@@ -2960,7 +2960,7 @@ static void cma_remove_one(struct ib_device *device)
 	kfree(cma_dev);
 }
 
-static int cma_init(void)
+static int __init cma_init(void)
 {
 	int ret, low, high, remaining;
 
@@ -2990,7 +2990,7 @@ err:
 	return ret;
 }
 
-static void cma_cleanup(void)
+static void __exit cma_cleanup(void)
 {
 	ib_unregister_client(&cma_client);
 	unregister_netdevice_notifier(&cma_nb);
#1 lore raw

Re: [PATCH] infiniband: adding __init/__exit macros to addr.c and

[ CCing Infiniband maintainers in case they prefer taking it through the
subsystem tree ]

Quoted 53 lines · Peter Hüwe

From: Peter Huewe <[email protected]>

Trivial patch which adds the __init and __exit macros to the module_init / module_exit functions from drivers/infiniband/core/addr.c and cma.c linux version 2.6.30

---

drivers/infiniband/core/addr.c +2 -2
index ce511d8..5be1bd4 100644
@@ -514,7 +514,7 @@ static struct notifier_block nb = {
 	.notifier_call = netevent_callback
 };
 
-static int addr_init(void)
+static int __init addr_init(void)
 {
 	addr_wq = create_singlethread_workqueue("ib_addr");
 	if (!addr_wq)
@@ -524,7 +524,7 @@ static int addr_init(void)
 	return 0;
 }
 
-static void addr_cleanup(void)
+static void __exit addr_cleanup(void)
 {
 	unregister_netevent_notifier(&nb);
 	destroy_workqueue(addr_wq);
drivers/infiniband/core/cma.c +2 -2
index 851de83..0753178 100644
@@ -2960,7 +2960,7 @@ static void cma_remove_one(struct ib_device *device)
 	kfree(cma_dev);
 }
 
-static int cma_init(void)
+static int __init cma_init(void)
 {
 	int ret, low, high, remaining;
 
@@ -2990,7 +2990,7 @@ err:
 	return ret;
 }
 
-static void cma_cleanup(void)
+static void __exit cma_cleanup(void)
 {
 	ib_unregister_client(&cma_client);
 	unregister_netdevice_notifier(&cma_nb);
Signature · 2 lines
Jiri Kosina
SUSE Labs
Acked-by on v1 1/1
#2 lore raw
In reply to Peter Hüwe
Quoted 7 lines
Quoted 7 lines

From: Peter Huewe <[email protected]>

Trivial patch which adds the __init and __exit macros to the module_init / module_exit functions from drivers/infiniband/core/addr.c and cma.c linux version 2.6.30

Roland, did you want to pull this through your tree?

Quoted 46 lines
Quoted 46 lines

---

drivers/infiniband/core/addr.c +2 -2
index ce511d8..5be1bd4 100644
@@ -514,7 +514,7 @@ static struct notifier_block nb = {
 	.notifier_call = netevent_callback
 };
 
-static int addr_init(void)
+static int __init addr_init(void)
 {
 	addr_wq = create_singlethread_workqueue("ib_addr");
 	if (!addr_wq)
@@ -524,7 +524,7 @@ static int addr_init(void)
 	return 0;
 }
 
-static void addr_cleanup(void)
+static void __exit addr_cleanup(void)
 {
 	unregister_netevent_notifier(&nb);
 	destroy_workqueue(addr_wq);
drivers/infiniband/core/cma.c +2 -2
index 851de83..0753178 100644
@@ -2960,7 +2960,7 @@ static void cma_remove_one(struct ib_device *device)
 	kfree(cma_dev);
 }
 
-static int cma_init(void)
+static int __init cma_init(void)
 {
 	int ret, low, high, remaining;
 
@@ -2990,7 +2990,7 @@ err:
 	return ret;
 }
 
-static void cma_cleanup(void)
+static void __exit cma_cleanup(void)
 {
 	ib_unregister_client(&cma_client);
 	unregister_netdevice_notifier(&cma_nb);
#3 lore raw
In reply to Peter Hüwe

Am Dienstag 16 Juni 2009 17:49:38 schrieb Sean Hefty:

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

From: Peter Huewe <[email protected]>

Trivial patch which adds the __init and __exit macros to the module_init / module_exit functions from drivers/infiniband/core/addr.c and cma.c linux version 2.6.30

Quoted 6 lines
Quoted 1 line
Quoted 1 line

Roland, did you want to pull this through your tree?

Hi,

may I ask what is the status of the patch?
Is it currently in any of your trees?

bye,
Peter

#4 lore raw
In reply to Peter Hüwe

I didn't see the original patch go by, but it's fine to go in through the trivial tree too. Otherwise please resend me the original patch and I'll queue it up.

author Acked-by Sean Hefty on v1 1/1
#5 lore raw
In reply to Peter Hüwe

From: Peter Huewe <[email protected]>

Trivial patch which adds the __init and __exit macros to the module_init / module_exit functions from drivers/infiniband/core/addr.c and cma.c linux version 2.6.30

---
Hi Roland,
here is the patch :) - it's really trivial I know.
I think it's faster to pull it through your tree, jini has a lot to do I guess.
Thanks, Peter

drivers/infiniband/core/addr.c +2 -2
index ce511d8..5be1bd4 100644
@@ -514,7 +514,7 @@ static struct notifier_block nb = {
 	.notifier_call = netevent_callback
 };
 
-static int addr_init(void)
+static int __init addr_init(void)
 {
 	addr_wq = create_singlethread_workqueue("ib_addr");
 	if (!addr_wq)
@@ -524,7 +524,7 @@ static int addr_init(void)
 	return 0;
 }
 
-static void addr_cleanup(void)
+static void __exit addr_cleanup(void)
 {
 	unregister_netevent_notifier(&nb);
 	destroy_workqueue(addr_wq);
drivers/infiniband/core/cma.c +2 -2
index 851de83..0753178 100644
@@ -2960,7 +2960,7 @@ static void cma_remove_one(struct ib_device *device)
 	kfree(cma_dev);
 }
 
-static int cma_init(void)
+static int __init cma_init(void)
 {
 	int ret, low, high, remaining;
 
@@ -2990,7 +2990,7 @@ err:
 	return ret;
 }
 
-static void cma_cleanup(void)
+static void __exit cma_cleanup(void)
 {
 	ib_unregister_client(&cma_client);
 	unregister_netdevice_notifier(&cma_nb);