From patchwork Wed Apr 10 14:22:14 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 16025 Return-Path: X-Original-To: linaro@staging.patches.linaro.org Delivered-To: linaro@staging.patches.linaro.org Received: from mail-vb0-f70.google.com (mail-vb0-f70.google.com [209.85.212.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 92C0E23912 for ; Wed, 10 Apr 2013 14:23:17 +0000 (UTC) Received: by mail-vb0-f70.google.com with SMTP id 11sf792932vbf.5 for ; Wed, 10 Apr 2013 07:22:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:x-beenthere:x-received:received-spf :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:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-google-group-id:list-post:list-help:list-archive:list-unsubscribe; bh=IyyTCQUDogZ4rVGVoyLqQ3clegrqFi5CjTFY/bIoOZg=; b=dPOx9mBzAcxUFlIUrW1YH77ytCCSpLfodamgk84RxAe0R2EOzdpiEicjhsO07J14xp sGLPAS9eSusekiyx9HyxuiMYA0ohyscL/a7icUcLtDWacw445HpgDUW6x3a3fzKwDIpd iP091irBQ1o/KtOluMOQlJX032NTJqN//uNfof0vzAum8FfMHIfLDyx0kGVVFk9aE893 PBmkgHCaxPtp5Ss6Gk7dkxXvB8Z2AclE+OwsTVuSlptF9SwiXZ7YSw47AojLQaDt7Jgx XbYiWloE6EEkhKBmY42xy6vhOy4N7W6EPQN3JYhGyKvTKGUVTl6na7uT/hXaYYvyn3mU N3GA== X-Received: by 10.236.74.34 with SMTP id w22mr1080196yhd.15.1365603778401; Wed, 10 Apr 2013 07:22:58 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.24.230 with SMTP id x6ls318256qef.31.gmail; Wed, 10 Apr 2013 07:22:58 -0700 (PDT) X-Received: by 10.58.45.71 with SMTP id k7mr1720434vem.0.1365603778202; Wed, 10 Apr 2013 07:22:58 -0700 (PDT) Received: from mail-ve0-f180.google.com (mail-ve0-f180.google.com [209.85.128.180]) by mx.google.com with ESMTPS id ex4si89707vdb.92.2013.04.10.07.22.58 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 10 Apr 2013 07:22:58 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.180 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.180; Received: by mail-ve0-f180.google.com with SMTP id c13so444624vea.39 for ; Wed, 10 Apr 2013 07:22:58 -0700 (PDT) X-Received: by 10.52.25.72 with SMTP id a8mr1421375vdg.47.1365603777898; Wed, 10 Apr 2013 07:22:57 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.58.85.136 with SMTP id h8csp107477vez; Wed, 10 Apr 2013 07:22:57 -0700 (PDT) X-Received: by 10.180.11.148 with SMTP id q20mr27165955wib.18.1365603777007; Wed, 10 Apr 2013 07:22:57 -0700 (PDT) Received: from mail-wg0-f46.google.com (mail-wg0-f46.google.com [74.125.82.46]) by mx.google.com with ESMTPS id vf9si57749wjc.42.2013.04.10.07.22.56 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 10 Apr 2013 07:22:57 -0700 (PDT) Received-SPF: neutral (google.com: 74.125.82.46 is neither permitted nor denied by best guess record for domain of daniel.lezcano@linaro.org) client-ip=74.125.82.46; Received: by mail-wg0-f46.google.com with SMTP id j13so533791wgh.25 for ; Wed, 10 Apr 2013 07:22:56 -0700 (PDT) X-Received: by 10.194.95.198 with SMTP id dm6mr4018359wjb.6.1365603776244; Wed, 10 Apr 2013 07:22:56 -0700 (PDT) Received: from mai.home (AToulouse-654-1-413-119.w82-125.abo.wanadoo.fr. [82.125.160.119]) by mx.google.com with ESMTPS id dp5sm32126938wib.1.2013.04.10.07.22.53 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 10 Apr 2013 07:22:55 -0700 (PDT) From: Daniel Lezcano To: rjw@sisk.pl Cc: linus.walleij@linaro.org, jason@lakedaemon.net, andrew@lunn.ch, kernel@pengutronix.de, swarren@wwwdotorg.org, santosh.shilimkar@ti.com, nicolas.ferre@atmel.com, plagnioj@jcrosoft.com, linux@maxim.org.za, rob.herring@calxeda.com, nsekhar@ti.com, horms@verge.net.au, magnus.damm@gmail.com, deepthi@linux.vnet.ibm.com, lethal@linux-sh.org, jkosina@suse.cz, kgene.kim@samsung.com, khilman@deeprootsystems.com, tony@atomide.com, linux-pm@vger.kernel.org, patches@linaro.org, linux-arm-kernel@lists.infradead.org, linaro-kernel@lists.linaro.org, josephl@nvidia.com Subject: [PATCH 09/18] ARM: s3c64xx: cpuidle: use init/exit common routine Date: Wed, 10 Apr 2013 16:22:14 +0200 Message-Id: <1365603743-5618-10-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1365603743-5618-1-git-send-email-daniel.lezcano@linaro.org> References: <1365603743-5618-1-git-send-email-daniel.lezcano@linaro.org> X-Gm-Message-State: ALoCoQmj16xKq+6VugFjkBU7Qam0KgyHwnhxI3dGvF4Z0TzbQWWKyXZyqINUDAf9SCG/XxqY3Nff X-Original-Sender: daniel.lezcano@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.180 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Remove the duplicated code and use the cpuidle common code for initialization. Signed-off-by: Daniel Lezcano --- arch/arm/mach-s3c64xx/cpuidle.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/arch/arm/mach-s3c64xx/cpuidle.c b/arch/arm/mach-s3c64xx/cpuidle.c index 852ff16..3c8ab07 100644 --- a/arch/arm/mach-s3c64xx/cpuidle.c +++ b/arch/arm/mach-s3c64xx/cpuidle.c @@ -40,8 +40,6 @@ static int s3c64xx_enter_idle(struct cpuidle_device *dev, return index; } -static DEFINE_PER_CPU(struct cpuidle_device, s3c64xx_cpuidle_device); - static struct cpuidle_driver s3c64xx_cpuidle_driver = { .name = "s3c64xx_cpuidle", .owner = THIS_MODULE, @@ -60,16 +58,6 @@ static struct cpuidle_driver s3c64xx_cpuidle_driver = { static int __init s3c64xx_init_cpuidle(void) { - int ret; - - cpuidle_register_driver(&s3c64xx_cpuidle_driver); - - ret = cpuidle_register_device(&s3c64xx_cpuidle_device); - if (ret) { - pr_err("Failed to register cpuidle device: %d\n", ret); - return ret; - } - - return 0; + return cpuidle_register(&s3c64xx_cpuidle_driver, NULL); } device_initcall(s3c64xx_init_cpuidle);