diff options
author | Samuel Ortiz <samuel@sortiz.org> | 2007-07-18 05:16:30 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2007-07-18 05:16:30 -0400 |
commit | 75a69ac6d66d2504ecbc4b46645fb0835a55a57c (patch) | |
tree | df2b3ee737b93f7cc6fe517d565cca1d579c2533 /net | |
parent | 83ca46e7ac7b2883ae7d02503a01e8f1578afe4e (diff) |
[IrDA]: Fix IrDA build failure
When having built-in IrDA, we hit the following error:
`irda_sysctl_unregister' referenced in section `.init.text' of
net/built-in.o: defined in discarded section `.exit.text' of
net/built-in.o
`irda_proc_unregister' referenced in section `.init.text' of
net/built-in.o: defined in discarded section `.exit.text' of
net/built-in.o
`irsock_cleanup' referenced in section `.init.text' of net/built-in.o:
defined in discarded section `.exit.text' of net/built-in.o
`irttp_cleanup' referenced in section `.init.text' of net/built-in.o:
defined in discarded section `.exit.text' of net/built-in.o
`iriap_cleanup' referenced in section `.init.text' of net/built-in.o:
defined in discarded section `.exit.text' of net/built-in.o
`irda_device_cleanup' referenced in section `.init.text' of
net/built-in.o: defined in discarded section `.exit.text' of
net/built-in.o
`irlap_cleanup' referenced in section `.init.text' of net/built-in.o:
defined in discarded section `.exit.text' of net/built-in.o
`irlmp_cleanup' referenced in section `.init.text' of net/built-in.o:
defined in discarded section `.exit.text' of net/built-in.o
make[1]: *** [.tmp_vmlinux1] Error 1
make: *** [_all] Error 2
This is due to the irda_init fix recently added, where we call __exit
routines from an __init one. It is a build failure that I didn't catch
because it doesn't show up when building IrDA as a module. My apologies
for that.
The following patch fixes that failure and is against your net-2.6
tree. I hope it can make it to the merge window, and stable@kernel.org
is CCed on this mail.
Signed-off-by: Samuel Ortiz <samuel@sortiz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/irda/af_irda.c | 2 | ||||
-rw-r--r-- | net/irda/irda_device.c | 4 | ||||
-rw-r--r-- | net/irda/iriap.c | 2 | ||||
-rw-r--r-- | net/irda/irlap.c | 2 | ||||
-rw-r--r-- | net/irda/irlmp.c | 2 | ||||
-rw-r--r-- | net/irda/irproc.c | 2 | ||||
-rw-r--r-- | net/irda/irsysctl.c | 2 | ||||
-rw-r--r-- | net/irda/irttp.c | 2 |
8 files changed, 9 insertions, 9 deletions
diff --git a/net/irda/af_irda.c b/net/irda/af_irda.c index dcd7e325b283..4c670cf6aefa 100644 --- a/net/irda/af_irda.c +++ b/net/irda/af_irda.c | |||
@@ -2567,7 +2567,7 @@ int __init irsock_init(void) | |||
2567 | * Remove IrDA protocol | 2567 | * Remove IrDA protocol |
2568 | * | 2568 | * |
2569 | */ | 2569 | */ |
2570 | void __exit irsock_cleanup(void) | 2570 | void irsock_cleanup(void) |
2571 | { | 2571 | { |
2572 | sock_unregister(PF_IRDA); | 2572 | sock_unregister(PF_IRDA); |
2573 | proto_unregister(&irda_proto); | 2573 | proto_unregister(&irda_proto); |
diff --git a/net/irda/irda_device.c b/net/irda/irda_device.c index 7b5def1ea633..435b563d29a6 100644 --- a/net/irda/irda_device.c +++ b/net/irda/irda_device.c | |||
@@ -95,14 +95,14 @@ int __init irda_device_init( void) | |||
95 | return 0; | 95 | return 0; |
96 | } | 96 | } |
97 | 97 | ||
98 | static void __exit leftover_dongle(void *arg) | 98 | static void leftover_dongle(void *arg) |
99 | { | 99 | { |
100 | struct dongle_reg *reg = arg; | 100 | struct dongle_reg *reg = arg; |
101 | IRDA_WARNING("IrDA: Dongle type %x not unregistered\n", | 101 | IRDA_WARNING("IrDA: Dongle type %x not unregistered\n", |
102 | reg->type); | 102 | reg->type); |
103 | } | 103 | } |
104 | 104 | ||
105 | void __exit irda_device_cleanup(void) | 105 | void irda_device_cleanup(void) |
106 | { | 106 | { |
107 | IRDA_DEBUG(4, "%s()\n", __FUNCTION__); | 107 | IRDA_DEBUG(4, "%s()\n", __FUNCTION__); |
108 | 108 | ||
diff --git a/net/irda/iriap.c b/net/irda/iriap.c index 774eb707940c..ee3889fa49ab 100644 --- a/net/irda/iriap.c +++ b/net/irda/iriap.c | |||
@@ -153,7 +153,7 @@ int __init iriap_init(void) | |||
153 | * Initializes the IrIAP layer, called by the module cleanup code in | 153 | * Initializes the IrIAP layer, called by the module cleanup code in |
154 | * irmod.c | 154 | * irmod.c |
155 | */ | 155 | */ |
156 | void __exit iriap_cleanup(void) | 156 | void iriap_cleanup(void) |
157 | { | 157 | { |
158 | irlmp_unregister_service(service_handle); | 158 | irlmp_unregister_service(service_handle); |
159 | 159 | ||
diff --git a/net/irda/irlap.c b/net/irda/irlap.c index 2fc9f518f89d..3d76aafdb2e5 100644 --- a/net/irda/irlap.c +++ b/net/irda/irlap.c | |||
@@ -95,7 +95,7 @@ int __init irlap_init(void) | |||
95 | return 0; | 95 | return 0; |
96 | } | 96 | } |
97 | 97 | ||
98 | void __exit irlap_cleanup(void) | 98 | void irlap_cleanup(void) |
99 | { | 99 | { |
100 | IRDA_ASSERT(irlap != NULL, return;); | 100 | IRDA_ASSERT(irlap != NULL, return;); |
101 | 101 | ||
diff --git a/net/irda/irlmp.c b/net/irda/irlmp.c index 24a5e3f23778..7efa930ed684 100644 --- a/net/irda/irlmp.c +++ b/net/irda/irlmp.c | |||
@@ -116,7 +116,7 @@ int __init irlmp_init(void) | |||
116 | * Remove IrLMP layer | 116 | * Remove IrLMP layer |
117 | * | 117 | * |
118 | */ | 118 | */ |
119 | void __exit irlmp_cleanup(void) | 119 | void irlmp_cleanup(void) |
120 | { | 120 | { |
121 | /* Check for main structure */ | 121 | /* Check for main structure */ |
122 | IRDA_ASSERT(irlmp != NULL, return;); | 122 | IRDA_ASSERT(irlmp != NULL, return;); |
diff --git a/net/irda/irproc.c b/net/irda/irproc.c index d6f9aba5b9dc..181cb51b48a8 100644 --- a/net/irda/irproc.c +++ b/net/irda/irproc.c | |||
@@ -84,7 +84,7 @@ void __init irda_proc_register(void) | |||
84 | * Unregister irda entry in /proc file system | 84 | * Unregister irda entry in /proc file system |
85 | * | 85 | * |
86 | */ | 86 | */ |
87 | void __exit irda_proc_unregister(void) | 87 | void irda_proc_unregister(void) |
88 | { | 88 | { |
89 | int i; | 89 | int i; |
90 | 90 | ||
diff --git a/net/irda/irsysctl.c b/net/irda/irsysctl.c index 2e968e7d8fea..957e04feb0f7 100644 --- a/net/irda/irsysctl.c +++ b/net/irda/irsysctl.c | |||
@@ -287,7 +287,7 @@ int __init irda_sysctl_register(void) | |||
287 | * Unregister our sysctl interface | 287 | * Unregister our sysctl interface |
288 | * | 288 | * |
289 | */ | 289 | */ |
290 | void __exit irda_sysctl_unregister(void) | 290 | void irda_sysctl_unregister(void) |
291 | { | 291 | { |
292 | unregister_sysctl_table(irda_table_header); | 292 | unregister_sysctl_table(irda_table_header); |
293 | } | 293 | } |
diff --git a/net/irda/irttp.c b/net/irda/irttp.c index 7f50832a2cd5..3d7ab03fb131 100644 --- a/net/irda/irttp.c +++ b/net/irda/irttp.c | |||
@@ -109,7 +109,7 @@ int __init irttp_init(void) | |||
109 | * Called by module destruction/cleanup code | 109 | * Called by module destruction/cleanup code |
110 | * | 110 | * |
111 | */ | 111 | */ |
112 | void __exit irttp_cleanup(void) | 112 | void irttp_cleanup(void) |
113 | { | 113 | { |
114 | /* Check for main structure */ | 114 | /* Check for main structure */ |
115 | IRDA_ASSERT(irttp->magic == TTP_MAGIC, return;); | 115 | IRDA_ASSERT(irttp->magic == TTP_MAGIC, return;); |