From patchwork Fri Sep 20 08:32:06 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 2915621 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 6BC719F1BF for ; Fri, 20 Sep 2013 08:32:04 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5E663203FD for ; Fri, 20 Sep 2013 08:32:03 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0CF77203B6 for ; Fri, 20 Sep 2013 08:32:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754195Ab3ITIb7 (ORCPT ); Fri, 20 Sep 2013 04:31:59 -0400 Received: from mail-pa0-f51.google.com ([209.85.220.51]:63854 "EHLO mail-pa0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754156Ab3ITIb5 (ORCPT ); Fri, 20 Sep 2013 04:31:57 -0400 Received: by mail-pa0-f51.google.com with SMTP id lf1so445183pab.24 for ; Fri, 20 Sep 2013 01:31:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=WdAIP+AMV/1f7U3PndSzfse1TztyiCqgn9p4hvR7NTI=; b=Z0kZwIGemB88Cl0Xn4D6rnt+Aa8+ICjQXkALz2aPFeg/EX+GY0FsxWMN524nZKjz69 PsWK59YY0LptMHtu9NlUoPjcVnq644J6Z95v+5clUaxxbtw2Jjv5yCeBVTLNlVyoDv7O HXM5oUx1Dk0wBAtPPEkLbxt3gF79NfDmw7Q05Gk+4xCz9TbFnrs7fw5uXwB95vdfZvaS haIEm4XMDZSquion9Zx2JSVfH9N3oHT+HG8XGFbYEUn+50dnE+8tCNR5seFnyxxWzy3g nThRX0brvln37Aud4LvoPq3vBLilNGyRO19BwUtTyVeN5b1tBqyB/9WqV5TYJ+KzHNOA bNqA== X-Gm-Message-State: ALoCoQkTD0ho5ZBjhip9kDgUcBnMBHCKHDFCXlPRlEnEJz477SyyWiUScqSo2P0uVLl0YpKaKvh2 X-Received: by 10.68.171.228 with SMTP id ax4mr6721605pbc.48.1379665917381; Fri, 20 Sep 2013 01:31:57 -0700 (PDT) Received: from linaro.sisodomain.com ([115.113.119.130]) by mx.google.com with ESMTPSA id py4sm14273729pbc.14.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 20 Sep 2013 01:31:57 -0700 (PDT) From: Sachin Kamat To: linux-media@vger.kernel.org Cc: m.chehab@samsung.com, Jelle Foks Subject: [PATCH 2/3] [media] pci: cx88-mpeg: Use module_pci_driver Date: Fri, 20 Sep 2013 14:02:06 +0530 Message-Id: <1379665927-18497-2-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1379665927-18497-1-git-send-email-sachin.kamat@linaro.org> References: <1379665927-18497-1-git-send-email-sachin.kamat@linaro.org> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP module_pci_driver removes some boilerplate and makes code simpler. Signed-off-by: Sachin Kamat Cc: Jelle Foks --- drivers/media/pci/cx88/cx88-mpeg.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/drivers/media/pci/cx88/cx88-mpeg.c b/drivers/media/pci/cx88/cx88-mpeg.c index 86d2008..684eff5 100644 --- a/drivers/media/pci/cx88/cx88-mpeg.c +++ b/drivers/media/pci/cx88/cx88-mpeg.c @@ -902,20 +902,8 @@ static struct pci_driver cx8802_pci_driver = { .remove = cx8802_remove, }; -static int __init cx8802_init(void) -{ - printk(KERN_INFO "cx88/2: cx2388x MPEG-TS Driver Manager version %s loaded\n", - CX88_VERSION); - return pci_register_driver(&cx8802_pci_driver); -} - -static void __exit cx8802_fini(void) -{ - pci_unregister_driver(&cx8802_pci_driver); -} +module_pci_driver(cx8802_pci_driver); -module_init(cx8802_init); -module_exit(cx8802_fini); EXPORT_SYMBOL(cx8802_buf_prepare); EXPORT_SYMBOL(cx8802_buf_queue); EXPORT_SYMBOL(cx8802_cancel_buffers);