From patchwork Thu Mar 14 17:09:36 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabio Porcedda X-Patchwork-Id: 2272841 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork2.kernel.org (Postfix) with ESMTP id D8756DFB79 for ; Thu, 14 Mar 2013 17:19:55 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UGBmC-0006sP-Fo; Thu, 14 Mar 2013 17:17:12 +0000 Received: from mail-ee0-f42.google.com ([74.125.83.42]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UGBlz-0006nz-Mk for linux-arm-kernel@lists.infradead.org; Thu, 14 Mar 2013 17:17:04 +0000 Received: by mail-ee0-f42.google.com with SMTP id b47so1151289eek.1 for ; Thu, 14 Mar 2013 10:16:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references; bh=L23OR5fbdOt8KPcv7RFuEFTd92KvdB420Y2NzLKlII0=; b=HCuKdU5rv0A79Kp3ZxHTM/A7LX7zoXyEp21kXSVRTOvO3sMAvsnF85EI2IJSJNp4yc q/kmV+xgcL89A1desNHl8emHzs8dxdZmEeHC9zxxZKZQIZDYaL7Bpv8zvNZ07K35+HQy xAM3G2FvWeFXiXD1JWaj9HaB+NAivoAyuzpMR/l8B35wbuOEofEBa2N3Xpv7K/q/RC98 3xW5yMphGrQ1Guly45zcyXJe+dQHCXjZXyoWl54wWzVj6kEWszx1f6Nz+ukRPByn4mt8 fVnniINuKANz2h3y30UuUFLm33ZkN9b4GgbbWZBVXw2TgqEQXeS3Rt3DKb4+MzZJqUVI A40g== X-Received: by 10.14.202.71 with SMTP id c47mr8608403eeo.39.1363280994776; Thu, 14 Mar 2013 10:09:54 -0700 (PDT) Received: from ld2036.tmt.telital.com ([213.205.6.118]) by mx.google.com with ESMTPS id 3sm4889138eej.6.2013.03.14.10.09.52 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 14 Mar 2013 10:09:53 -0700 (PDT) From: Fabio Porcedda To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-media@vger.kernel.org, linux-ide@vger.kernel.org, linux-input@vger.kernel.org, linux-fbdev@vger.kernel.org Subject: [PATCH v2 6/8] drivers: mfd: use module_platform_driver_probe() Date: Thu, 14 Mar 2013 18:09:36 +0100 Message-Id: <1363280978-24051-7-git-send-email-fabio.porcedda@gmail.com> X-Mailer: git-send-email 1.8.1.5 In-Reply-To: <1363280978-24051-1-git-send-email-fabio.porcedda@gmail.com> References: <1363280978-24051-1-git-send-email-fabio.porcedda@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130314_131659_908781_B6FCD4CE X-CRM114-Status: GOOD ( 11.34 ) X-Spam-Score: -0.2 (/) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-0.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [74.125.83.42 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (fabio.porcedda[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 2.5 SUSPICIOUS_RECIPS Similar addresses in recipient list -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature Cc: Greg Kroah-Hartman , Linus Walleij , Samuel Ortiz X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org This patch converts the drivers to use the module_platform_driver_probe() macro which makes the code smaller and a bit simpler. Signed-off-by: Fabio Porcedda Cc: Greg Kroah-Hartman Cc: Linus Walleij Cc: Samuel Ortiz Cc: linux-arm-kernel@lists.infradead.org --- drivers/mfd/davinci_voicecodec.c | 12 +----------- drivers/mfd/htc-pasic3.c | 13 +------------ 2 files changed, 2 insertions(+), 23 deletions(-) diff --git a/drivers/mfd/davinci_voicecodec.c b/drivers/mfd/davinci_voicecodec.c index c0bcc87..c60ab0c 100644 --- a/drivers/mfd/davinci_voicecodec.c +++ b/drivers/mfd/davinci_voicecodec.c @@ -177,17 +177,7 @@ static struct platform_driver davinci_vc_driver = { .remove = davinci_vc_remove, }; -static int __init davinci_vc_init(void) -{ - return platform_driver_probe(&davinci_vc_driver, davinci_vc_probe); -} -module_init(davinci_vc_init); - -static void __exit davinci_vc_exit(void) -{ - platform_driver_unregister(&davinci_vc_driver); -} -module_exit(davinci_vc_exit); +module_platform_driver_probe(davinci_vc_driver, davinci_vc_probe); MODULE_AUTHOR("Miguel Aguilar"); MODULE_DESCRIPTION("Texas Instruments DaVinci Voice Codec Core Interface"); diff --git a/drivers/mfd/htc-pasic3.c b/drivers/mfd/htc-pasic3.c index 9e5453d..0285fce 100644 --- a/drivers/mfd/htc-pasic3.c +++ b/drivers/mfd/htc-pasic3.c @@ -208,18 +208,7 @@ static struct platform_driver pasic3_driver = { .remove = pasic3_remove, }; -static int __init pasic3_base_init(void) -{ - return platform_driver_probe(&pasic3_driver, pasic3_probe); -} - -static void __exit pasic3_base_exit(void) -{ - platform_driver_unregister(&pasic3_driver); -} - -module_init(pasic3_base_init); -module_exit(pasic3_base_exit); +module_platform_driver_probe(pasic3_driver, pasic3_probe); MODULE_AUTHOR("Philipp Zabel "); MODULE_DESCRIPTION("Core driver for HTC PASIC3");