Skip to contentSkip to conversation

drivers/isdn/gigaset: build asyncdata.o into the gigaset module (v2)

PATCH New Tilman Schmidt 1 participant 1 message Feb 20, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drivers/isdn/gigaset: build asyncdata.o into the gigaset module (v2)

a) Fix link error from double inclusion of asyncdata.o when building both M10x drivers into the kernel, by moving it into the common part.

b) Correct the rule for building the common part into the kernel when some or all hardware specific parts are built as modules.

---

This patch is based on 2.6.20-git14. Please replace patch drivers-isdn-gigaset-build-asyncdatao-into-the-gigaset-module.patch in the -mm tree by this.

 Makefile    |   13 +++++++------
 asyncdata.c |    7 ++-----
 2 files changed, 9 insertions(+), 11 deletions(-)
drivers/isdn/gigaset/asyncdata.c +2 -5
diff -up linux-2.6.20-work/drivers/isdn/gigaset/asyncdata.c local/drivers/isdn/gigaset/asyncdata.c
@@ -13,11 +13,6 @@
  * =====================================================================
  */
 
-/* not set by Kbuild when building both ser_gigaset and usb_gigaset */
-#ifndef KBUILD_MODNAME
-#define KBUILD_MODNAME "asy_gigaset"
-#endif
-
 #include "gigaset.h"
 #include <linux/crc-ccitt.h>
 #include <linux/bitrev.h>
@@ -444,6 +439,7 @@ nextbyte:
 		atomic_set(&inbuf->head, head);
 	}
 }
+EXPORT_SYMBOL_GPL(gigaset_m10x_input);
 
 
 /* == data output ========================================================== */
@@ -591,3 +587,4 @@ int gigaset_m10x_send_skb(struct bc_stat
 
 	return len;	/* ok so far */
 }
+EXPORT_SYMBOL_GPL(gigaset_m10x_send_skb);
drivers/isdn/gigaset/Makefile +7 -6
diff -up linux-2.6.20-work/drivers/isdn/gigaset/Makefile local/drivers/isdn/gigaset/Makefile
@@ -1,8 +1,9 @@
-gigaset-y := common.o interface.o proc.o ev-layer.o i4l.o
-usb_gigaset-y := usb-gigaset.o asyncdata.o
+gigaset-y := common.o interface.o proc.o ev-layer.o i4l.o asyncdata.o
+usb_gigaset-y := usb-gigaset.o
+ser_gigaset-y := ser-gigaset.o
 bas_gigaset-y := bas-gigaset.o isocdata.o
-ser_gigaset-y := ser-gigaset.o asyncdata.o
 
-obj-$(CONFIG_GIGASET_M105) += usb_gigaset.o gigaset.o
-obj-$(CONFIG_GIGASET_BASE) += bas_gigaset.o gigaset.o
-obj-$(CONFIG_GIGASET_M101) += ser_gigaset.o gigaset.o
+obj-$(CONFIG_ISDN_DRV_GIGASET) += gigaset.o
+obj-$(CONFIG_GIGASET_M105) += usb_gigaset.o
+obj-$(CONFIG_GIGASET_M101) += ser_gigaset.o
+obj-$(CONFIG_GIGASET_BASE) += bas_gigaset.o
Signature · 4 lines
Tilman Schmidt                          E-Mail: [email protected]
Bonn, Germany
- In theory, there is no difference between theory and practice.
  In practice, there is.