From patchwork Thu Apr 11 20:42:40 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 16058 Return-Path: X-Original-To: linaro@staging.patches.linaro.org Delivered-To: linaro@staging.patches.linaro.org Received: from mail-ve0-f198.google.com (mail-ve0-f198.google.com [209.85.128.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 0F522238FF for ; Thu, 11 Apr 2013 20:43:44 +0000 (UTC) Received: by mail-ve0-f198.google.com with SMTP id ox1sf3374264veb.5 for ; Thu, 11 Apr 2013 13:43:22 -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=lf5ucGzj+cVPgKN+vaBW1uaiVlz44gRXj2DTWOZE+sp2EAYnjP4BRinkDhyG8TstkK rZJg43IyoO2lPsWdvYWcnSWHSYrJKZbh4xT0tNH5ADumDrlCpiJBbIWU7y2RKbeEsTt7 Xr5RL2u/+YsDTcLxPv3VruWKk8+bC6wOuf+D8iHARQQolHChCiN/DJC7jp+mDZNTTvJe 7pIr09rGvEAhEBG5HpH5g7CG2qEK/4+eDcWiIniwKrpUud3uDBHTtNxCdL15Ea7PgCwU cO/5bOCP2qS/VdsMUEF1gbPXyifBNWa6xR9YnJAc3HDNJauBmVLOEn4InrARifpFwNs6 0p6A== X-Received: by 10.224.160.65 with SMTP id m1mr4665682qax.2.1365713001931; Thu, 11 Apr 2013 13:43:21 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.1.4 with SMTP id 4ls1093426qei.68.gmail; Thu, 11 Apr 2013 13:43:21 -0700 (PDT) X-Received: by 10.52.162.71 with SMTP id xy7mr5441933vdb.11.1365713001712; Thu, 11 Apr 2013 13:43:21 -0700 (PDT) Received: from mail-vb0-x22c.google.com (mail-vb0-x22c.google.com [2607:f8b0:400c:c02::22c]) by mx.google.com with ESMTPS id dl5si4385396ved.17.2013.04.11.13.43.21 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 11 Apr 2013 13:43:21 -0700 (PDT) Received-SPF: neutral (google.com: 2607:f8b0:400c:c02::22c is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=2607:f8b0:400c:c02::22c; Received: by mail-vb0-f44.google.com with SMTP id e12so1645617vbg.3 for ; Thu, 11 Apr 2013 13:43:21 -0700 (PDT) X-Received: by 10.52.163.231 with SMTP id yl7mr5400113vdb.57.1365713001583; Thu, 11 Apr 2013 13:43:21 -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.127.98 with SMTP id nf2csp38028veb; Thu, 11 Apr 2013 13:43:21 -0700 (PDT) X-Received: by 10.194.171.74 with SMTP id as10mr13342527wjc.0.1365713000633; Thu, 11 Apr 2013 13:43:20 -0700 (PDT) Received: from mail-wg0-f53.google.com (mail-wg0-f53.google.com [74.125.82.53]) by mx.google.com with ESMTPS id dm9si1402990wib.69.2013.04.11.13.43.20 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 11 Apr 2013 13:43:20 -0700 (PDT) Received-SPF: neutral (google.com: 74.125.82.53 is neither permitted nor denied by best guess record for domain of daniel.lezcano@linaro.org) client-ip=74.125.82.53; Received: by mail-wg0-f53.google.com with SMTP id c11so2046750wgh.8 for ; Thu, 11 Apr 2013 13:43:20 -0700 (PDT) X-Received: by 10.180.82.33 with SMTP id f1mr36451340wiy.13.1365713000164; Thu, 11 Apr 2013 13:43:20 -0700 (PDT) Received: from mai.home (AToulouse-654-1-501-244.w83-205.abo.wanadoo.fr. [83.205.84.244]) by mx.google.com with ESMTPS id fv2sm5794029wib.6.2013.04.11.13.43.17 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 11 Apr 2013 13:43:19 -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: [V2 patch 10/19] ARM: s3c64xx: cpuidle: use init/exit common routine Date: Thu, 11 Apr 2013 22:42:40 +0200 Message-Id: <1365712969-7541-11-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1365712969-7541-1-git-send-email-daniel.lezcano@linaro.org> References: <1365712969-7541-1-git-send-email-daniel.lezcano@linaro.org> X-Gm-Message-State: ALoCoQnOUXwXcjYeW3iizlWYoVclnnxs98jC06dOgHHpWyFqk9bA5Q8WcOVIDFzM6dwlFP2i0DMI X-Original-Sender: daniel.lezcano@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 2607:f8b0:400c:c02::22c 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);