From patchwork Fri Feb 15 12:45:01 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 14876 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 9C89023E2E for ; Fri, 15 Feb 2013 12:47:00 +0000 (UTC) Received: from mail-ve0-f180.google.com (mail-ve0-f180.google.com [209.85.128.180]) by fiordland.canonical.com (Postfix) with ESMTP id 57F9EA197C4 for ; Fri, 15 Feb 2013 12:47:00 +0000 (UTC) Received: by mail-ve0-f180.google.com with SMTP id jx10so2915768veb.39 for ; Fri, 15 Feb 2013 04:46:59 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:x-received:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references:x-gm-message-state; bh=4c55pADba+U1aTJMlH0iXlBYiGg51LZJtQVSs4T8i20=; b=GJgQK4UK3DUCFk+0BPGUKi3QSxYAM3mHf+jyx9vdCQQQFLGXSV9v9mkBCWD2aLvkhv lfxOSkLz80B+Tv91SRO8xwTBrhBNLZoiCkrXbBkwX2eRkDl9+nAPlp6nq80IexuRXQCu ZqxwrJPVkEA3XbfhdSF3r9EMrw1XvZsOIBcsVkMao+rY6O2dbbh7q+DMoHFuC4/v7MZO qKbJqa12Q+otTN2TRb+udRd/q7IDMmUUHSrUu8IF2NDf0gN0+FQklxdrwGxm2kPWtOQj l0shLyWGz6Niu9a+tPauN3GPlwdBoTqzdqaK6TAcCxCVns6THf9gQblar0lVDQdkRhat o7aQ== X-Received: by 10.52.33.167 with SMTP id s7mr2512338vdi.52.1360932419850; Fri, 15 Feb 2013 04:46:59 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.221.4.5 with SMTP id oa5csp10903vcb; Fri, 15 Feb 2013 04:46:59 -0800 (PST) X-Received: by 10.194.156.170 with SMTP id wf10mr4000402wjb.25.1360932410799; Fri, 15 Feb 2013 04:46:50 -0800 (PST) Received: from mail-wi0-f172.google.com (mail-wi0-f172.google.com [209.85.212.172]) by mx.google.com with ESMTPS id ls4si6830773wjb.21.2013.02.15.04.46.50 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 15 Feb 2013 04:46:50 -0800 (PST) Received-SPF: neutral (google.com: 209.85.212.172 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) client-ip=209.85.212.172; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.212.172 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) smtp.mail=lee.jones@linaro.org Received: by mail-wi0-f172.google.com with SMTP id ez12so1092285wid.17 for ; Fri, 15 Feb 2013 04:46:50 -0800 (PST) X-Received: by 10.194.76.237 with SMTP id n13mr3860791wjw.57.1360932410397; Fri, 15 Feb 2013 04:46:50 -0800 (PST) Received: from localhost.localdomain (cpc34-aztw25-2-0-cust250.18-1.cable.virginmedia.com. [86.16.136.251]) by mx.google.com with ESMTPS id bs6sm5133904wib.4.2013.02.15.04.46.48 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 15 Feb 2013 04:46:49 -0800 (PST) From: Lee Jones To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: arnd@arndb.de, linus.walleij@stericsson.com, cbouatmailru@gmail.com, sameo@linux.intel.com, srinidhi kasagar , Lee Jones Subject: [PATCH 31/40] abx500-chargalg: Use module_platform_driver() rather Date: Fri, 15 Feb 2013 12:45:01 +0000 Message-Id: <1360932310-30065-32-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1360932310-30065-1-git-send-email-lee.jones@linaro.org> References: <1360932310-30065-1-git-send-email-lee.jones@linaro.org> X-Gm-Message-State: ALoCoQlaPJw7T+qp99yC/h10js967SvDyw0pHha3EGZPGvia+T12Mlig5JL72Bx3KGySWeUPHH+8 From: srinidhi kasagar deprecate some boilerplate code by using module_platform_driver helper macro. No functional changes. Signed-off-by: srinidhi kasagar Signed-off-by: Lee Jones --- drivers/power/abx500_chargalg.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/drivers/power/abx500_chargalg.c b/drivers/power/abx500_chargalg.c index 55c9d2e..7e4bc01 100644 --- a/drivers/power/abx500_chargalg.c +++ b/drivers/power/abx500_chargalg.c @@ -2083,18 +2083,7 @@ static struct platform_driver abx500_chargalg_driver = { }, }; -static int __init abx500_chargalg_init(void) -{ - return platform_driver_register(&abx500_chargalg_driver); -} - -static void __exit abx500_chargalg_exit(void) -{ - platform_driver_unregister(&abx500_chargalg_driver); -} - -module_init(abx500_chargalg_init); -module_exit(abx500_chargalg_exit); +module_platform_driver(abx500_chargalg_driver); MODULE_LICENSE("GPL v2"); MODULE_AUTHOR("Johan Palsson, Karl Komierowski");