From patchwork Fri Apr 11 10:39:57 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 28276 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pa0-f69.google.com (mail-pa0-f69.google.com [209.85.220.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 388D620A72 for ; Fri, 11 Apr 2014 10:41:29 +0000 (UTC) Received: by mail-pa0-f69.google.com with SMTP id fb1sf17512306pad.4 for ; Fri, 11 Apr 2014 03:41:29 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=lDIiyCLa1ehAepk380gVYEJe6wPvz8ICK+TmWztytc8=; b=S+Uc6qlDH2BAfWwrkAk/O8ros0E5meCo4MWhUUcFcDFOktDR/77pzhZcnHDDGJtm0D 5mtH8n8yTVAuPy80todz9zpVJyTLbRin2GurUsoexOriRNmm067deRwMwt/45iEezqUX Fci95eRJ07Rh5QdcOykGnsemSKSfiX2ix45fZfRhIJ4fgfD44rPCuV4fceEzpZ916Zj9 Ajx3eg6M5ZSSbaeXdAOhqFdwBBz/yveDn/Kw6E6203QTELa4m7t7BfchnvrI2KYdZigK 0egu3e3sFLMjpECdwRObVy9iooMdJrniKsbl79wG9cxWiSOUJ/hKOpA6PGJY6EVwAY3X xXEA== X-Gm-Message-State: ALoCoQkWv+EJlqqPJNkhMEv+ruY1SV4E356nrZar7CFrGZRtp7u/tJsOkmyE8Cao77Pu2gUI6/wo X-Received: by 10.66.240.4 with SMTP id vw4mr10704608pac.10.1397212889303; Fri, 11 Apr 2014 03:41:29 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.80.145 with SMTP id c17ls1567397qgd.60.gmail; Fri, 11 Apr 2014 03:41:29 -0700 (PDT) X-Received: by 10.220.159.4 with SMTP id h4mr19527545vcx.1.1397212889182; Fri, 11 Apr 2014 03:41:29 -0700 (PDT) Received: from mail-ve0-f176.google.com (mail-ve0-f176.google.com [209.85.128.176]) by mx.google.com with ESMTPS id kj3si627072vdb.150.2014.04.11.03.41.29 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Apr 2014 03:41:29 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.176 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.176; Received: by mail-ve0-f176.google.com with SMTP id db11so4639955veb.35 for ; Fri, 11 Apr 2014 03:41:29 -0700 (PDT) X-Received: by 10.52.249.105 with SMTP id yt9mr399954vdc.34.1397212889111; Fri, 11 Apr 2014 03:41:29 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.221.72 with SMTP id ib8csp46229vcb; Fri, 11 Apr 2014 03:41:28 -0700 (PDT) X-Received: by 10.66.66.202 with SMTP id h10mr3695082pat.70.1397212888147; Fri, 11 Apr 2014 03:41:28 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id xk5si3953032pbc.400.2014.04.11.03.41.27; Fri, 11 Apr 2014 03:41:27 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-samsung-soc-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757149AbaDKKl0 (ORCPT + 8 others); Fri, 11 Apr 2014 06:41:26 -0400 Received: from mail-wg0-f46.google.com ([74.125.82.46]:55063 "EHLO mail-wg0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932575AbaDKKkA (ORCPT ); Fri, 11 Apr 2014 06:40:00 -0400 Received: by mail-wg0-f46.google.com with SMTP id b13so5246112wgh.5 for ; Fri, 11 Apr 2014 03:39:59 -0700 (PDT) X-Received: by 10.194.20.229 with SMTP id q5mr813059wje.86.1397212798921; Fri, 11 Apr 2014 03:39:58 -0700 (PDT) Received: from localhost.localdomain (AToulouse-654-1-377-242.w86-199.abo.wanadoo.fr. [86.199.232.242]) by mx.google.com with ESMTPSA id eq8sm3683033wib.16.2014.04.11.03.39.57 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Apr 2014 03:39:58 -0700 (PDT) From: Daniel Lezcano To: kgene.kim@samsung.com Cc: linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, t.figa@samsung.com, linaro-kernel@lists.linaro.org, rjw@rjwysocki.net Subject: [PATCH V5 02/20] ARM: exynos: cpuidle: Prevent forward declaration Date: Fri, 11 Apr 2014 12:39:57 +0200 Message-Id: <1397212815-16068-3-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1397212815-16068-1-git-send-email-daniel.lezcano@linaro.org> References: <1397212815-16068-1-git-send-email-daniel.lezcano@linaro.org> Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: daniel.lezcano@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.176 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 Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Move the structure below the 'exynos4_enter_lowpower' function so no more need of forward declaration. Signed-off-by: Daniel Lezcano Reviewed-by: Viresh Kumar Reviewed-by: Bartlomiej Zolnierkiewicz Reviewed-by: Tomasz Figa --- arch/arm/mach-exynos/cpuidle.c | 40 ++++++++++++++++++---------------------- 1 file changed, 18 insertions(+), 22 deletions(-) diff --git a/arch/arm/mach-exynos/cpuidle.c b/arch/arm/mach-exynos/cpuidle.c index 3e260ba..17df0d8 100644 --- a/arch/arm/mach-exynos/cpuidle.c +++ b/arch/arm/mach-exynos/cpuidle.c @@ -40,30 +40,8 @@ #define S5P_CHECK_AFTR 0xFCBA0D10 -static int exynos4_enter_lowpower(struct cpuidle_device *dev, - struct cpuidle_driver *drv, - int index); - static DEFINE_PER_CPU(struct cpuidle_device, exynos4_cpuidle_device); -static struct cpuidle_driver exynos4_idle_driver = { - .name = "exynos4_idle", - .owner = THIS_MODULE, - .states = { - [0] = ARM_CPUIDLE_WFI_STATE, - [1] = { - .enter = exynos4_enter_lowpower, - .exit_latency = 300, - .target_residency = 100000, - .flags = CPUIDLE_FLAG_TIME_VALID, - .name = "C1", - .desc = "ARM power down", - }, - }, - .state_count = 2, - .safe_state_index = 0, -}; - /* Ext-GIC nIRQ/nFIQ is the only wakeup source in AFTR */ static void exynos4_set_wakeupmask(void) { @@ -162,6 +140,24 @@ static int exynos4_enter_lowpower(struct cpuidle_device *dev, return exynos4_enter_core0_aftr(dev, drv, new_index); } +static struct cpuidle_driver exynos4_idle_driver = { + .name = "exynos4_idle", + .owner = THIS_MODULE, + .states = { + [0] = ARM_CPUIDLE_WFI_STATE, + [1] = { + .enter = exynos4_enter_lowpower, + .exit_latency = 300, + .target_residency = 100000, + .flags = CPUIDLE_FLAG_TIME_VALID, + .name = "C1", + .desc = "ARM power down", + }, + }, + .state_count = 2, + .safe_state_index = 0, +}; + static int exynos_cpuidle_probe(struct platform_device *pdev) { int cpu_id, ret;