From patchwork Sun Apr 5 11:42:11 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Uri Shkolnik X-Patchwork-Id: 16416 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n35BgEak029849 for ; Sun, 5 Apr 2009 11:42:14 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751016AbZDELmO (ORCPT ); Sun, 5 Apr 2009 07:42:14 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752614AbZDELmO (ORCPT ); Sun, 5 Apr 2009 07:42:14 -0400 Received: from web110804.mail.gq1.yahoo.com ([67.195.13.227]:32871 "HELO web110804.mail.gq1.yahoo.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1751016AbZDELmN (ORCPT ); Sun, 5 Apr 2009 07:42:13 -0400 Received: (qmail 69925 invoked by uid 60001); 5 Apr 2009 11:42:11 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1238931731; bh=nfnIp9UDtQpx21CuGM3t4+AFks4Lh1QksuLNqr5IZHE=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type; b=QIPKxsG3evzAP1m6VAkbiggIIT7ILcVH4l3n16iKd0OA0WklrcP8PHheGtgPY2k0zdmaYfv0UIecr9ij+b2S1AOouB27pH2acWrgCGAMeERTcWb6MqkNNN2tAVEA7B8xIqufGQ4dxVH/PLEArnuKalSxdD4RmsFv6oOVZpFJ7JA= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type; b=MQx89fYwf8A4r8uD9BAU1OJId3KyK10OpeXf1klWto6cSgocTKY0o2aZz7H4VXbtuJL5p/VmBkGGKIYdFrDa55PgMjNzV8MrT1bJsGpalAgLeY5rZah51ZSAcJhlr7bd0kDlz2W6Zf6qvri+o27RXKrxbSL7pw4+WV6LZ43DaKI=; Message-ID: <629811.69312.qm@web110804.mail.gq1.yahoo.com> X-YMail-OSG: z8jBuBIVM1k4xJqpVQDGUUoMZyRnnYape4mQ5NOvtKFEySbqcKD9YY8CWroAm8NwFyMHCB0QyZFs.QSWtl2HSHQedGRBbNTqBVxjgCQhTtjWihB1h4qlK.kbaLJjNsCsapoQ4ZHC7HvMmt287z5afFpALrf8vf9ci.A3r.rOD8Hb4Y7PCTSOARxwyZd7S0WPEIQrppTCdC.OsycpM8mUre7efGCoRxzo0CxavZ8hLrirDNpQcv4tgAk8cOvMP3fKkUbXBVu6qycxADRYDLU4PAa_EeLSdXg7s7ydEHY6T8A2bDVYzpd8xThSAzvAELRwGohXmrUp25Ip3b.5hW13cIbDr4O_sXiv4Yd7j3LI Received: from [199.203.99.233] by web110804.mail.gq1.yahoo.com via HTTP; Sun, 05 Apr 2009 04:42:11 PDT X-Mailer: YahooMailClassic/5.2.15 YahooMailWebService/0.7.289.1 Date: Sun, 5 Apr 2009 04:42:11 -0700 (PDT) From: Uri Shkolnik Subject: [PATCH] [0904_14] Siano: assemble all components to one kernel module To: LinuxML MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org # HG changeset patch # User Uri Shkolnik # Date 1238756860 -10800 # Node ID 616e696ce6f0c0d76a1aaea8b36e0345112c5ab6 # Parent f65a29f0f9a66f82a91525ae0085a15f00ac91c2 [PATCH] [0904_14] Siano: assemble all components to one kernel module From: Uri Shkolnik Previously, the support for Siano-based devices has been combined from several kernel modules. This patch assembles all into single kernel module. Priority: normal Signed-off-by: Uri Shkolnik --- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff -r f65a29f0f9a6 -r 616e696ce6f0 linux/drivers/media/dvb/siano/Makefile --- a/linux/drivers/media/dvb/siano/Makefile Fri Apr 03 13:40:04 2009 +0300 +++ b/linux/drivers/media/dvb/siano/Makefile Fri Apr 03 14:07:40 2009 +0300 @@ -1,8 +1,6 @@ sms1xxx-objs := smscoreapi.o sms-cards.o -sms1xxx-objs := smscoreapi.o sms-cards.o +sms1xxx-objs := smscoreapi.o sms-cards.o smsusb.o smsdvb.o smsendian.o obj-$(CONFIG_DVB_SIANO_SMS1XXX) += sms1xxx.o -obj-$(CONFIG_DVB_SIANO_SMS1XXX) += smsusb.o -obj-$(CONFIG_DVB_SIANO_SMS1XXX) += smsdvb.o EXTRA_CFLAGS += -Idrivers/media/dvb/dvb-core diff -r f65a29f0f9a6 -r 616e696ce6f0 linux/drivers/media/dvb/siano/smscoreapi.c --- a/linux/drivers/media/dvb/siano/smscoreapi.c Fri Apr 03 13:40:04 2009 +0300 +++ b/linux/drivers/media/dvb/siano/smscoreapi.c Fri Apr 03 14:07:40 2009 +0300 @@ -1321,8 +1321,8 @@ static int __init smscore_module_init(vo } #endif -#if 0 /* def SMS_DVB_CLIENT */ - /* DVB Register */ +#ifdef SMS_DVB3_SUBSYS + /* DVB v.3 Register */ rc = smsdvb_register(); if (rc) { sms_err("Error registering DVB client.\n"); @@ -1339,7 +1339,7 @@ static int __init smscore_module_init(vo } #endif -#if 0 /* def SMS_USB_BUS_DRV */ +#ifdef SMS_USB_DRV /* USB Register */ rc = smsusb_register(); if (rc) { @@ -1385,8 +1385,7 @@ static void __exit smscore_module_exit(v smschar_unregister(); #endif -#if 0 /* def SMS_DVB_CLIENT */ - /* DVB UnRegister */ +#ifdef SMS_DVB3_SUBSYS smsdvb_unregister(); #endif @@ -1395,8 +1394,9 @@ static void __exit smscore_module_exit(v smsnet_unregister(); #endif -#if 0 /* def SMS_USB_BUS_DRV */ - /* Unregister USB */ + /* Unegister interfaces objects */ +#ifdef SMS_USB_DRV + /* USB unregister */ smsusb_unregister(); #endif diff -r f65a29f0f9a6 -r 616e696ce6f0 linux/drivers/media/dvb/siano/smscoreapi.h --- a/linux/drivers/media/dvb/siano/smscoreapi.h Fri Apr 03 13:40:04 2009 +0300 +++ b/linux/drivers/media/dvb/siano/smscoreapi.h Fri Apr 03 14:07:40 2009 +0300 @@ -617,6 +617,17 @@ int smscore_get_board_id(struct smscore_ int smscore_led_state(struct smscore_device_t *core, int led); + +#ifdef SMS_DVB3_SUBSYS +extern int smsdvb_register(void); +extern void smsdvb_unregister(void); +#endif + +#ifdef SMS_USB_DRV +extern int smsusb_register(void); +extern void smsusb_unregister(void); +#endif + /* ------------------------------------------------------------------------ */ #define DBG_INFO 1 diff -r f65a29f0f9a6 -r 616e696ce6f0 linux/drivers/media/dvb/siano/smsdvb.c --- a/linux/drivers/media/dvb/siano/smsdvb.c Fri Apr 03 13:40:04 2009 +0300 +++ b/linux/drivers/media/dvb/siano/smsdvb.c Fri Apr 03 14:07:40 2009 +0300 @@ -638,7 +638,7 @@ adapter_error: return rc; } -int smsdvb_module_init(void) +int smsdvb_register(void) { int rc; @@ -652,7 +652,7 @@ int smsdvb_module_init(void) return rc; } -void smsdvb_module_exit(void) +void smsdvb_unregister(void) { smscore_unregister_hotplug(smsdvb_hotplug); @@ -665,9 +665,6 @@ void smsdvb_module_exit(void) kmutex_unlock(&g_smsdvb_clientslock); } -module_init(smsdvb_module_init); -module_exit(smsdvb_module_exit); - MODULE_DESCRIPTION("SMS DVB subsystem adaptation module"); MODULE_AUTHOR("Siano Mobile Silicon, INC. (uris@siano-ms.com)"); MODULE_LICENSE("GPL"); diff -r f65a29f0f9a6 -r 616e696ce6f0 linux/drivers/media/dvb/siano/smsusb.c --- a/linux/drivers/media/dvb/siano/smsusb.c Fri Apr 03 13:40:04 2009 +0300 +++ b/linux/drivers/media/dvb/siano/smsusb.c Fri Apr 03 14:07:40 2009 +0300 @@ -539,7 +539,7 @@ static struct usb_driver smsusb_driver = .resume = smsusb_resume, }; -int smsusb_module_init(void) +int smsusb_register(void) { int rc = usb_register(&smsusb_driver); if (rc) @@ -550,16 +550,13 @@ int smsusb_module_init(void) return rc; } -void smsusb_module_exit(void) +void smsusb_unregister(void) { - sms_debug(""); /* Regular USB Cleanup */ usb_deregister(&smsusb_driver); + sms_info("end"); } -module_init(smsusb_module_init); -module_exit(smsusb_module_exit); - -MODULE_DESCRIPTION("Driver for the Siano SMS1XXX USB dongle"); +MODULE_DESCRIPTION("Driver for the Siano SMS1xxx USB dongle"); MODULE_AUTHOR("Siano Mobile Silicon, INC. (uris@siano-ms.com)"); MODULE_LICENSE("GPL");