From patchwork Wed Apr 4 09:42:13 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 7608 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 A4CC123E4C for ; Wed, 4 Apr 2012 09:42:43 +0000 (UTC) Received: from mail-iy0-f180.google.com (mail-iy0-f180.google.com [209.85.210.180]) by fiordland.canonical.com (Postfix) with ESMTP id 6E548A1800C for ; Wed, 4 Apr 2012 09:42:43 +0000 (UTC) Received: by mail-iy0-f180.google.com with SMTP id e36so109604iag.11 for ; Wed, 04 Apr 2012 02:42:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=NH7RcoKLUDXslaj6BTqPxYU9RwtlFaW7bkEnWMLqrgU=; b=nQ2qRsHGv4MMa60w2o+wSmhjin41KAhu4vfWPWzIMy8pftQ+ae81fSpY0W/dKmzG1a OoEnAx+6ihrEQRHCsiDdFP1STx+uo2kAQo/s8oLCBBmH+5EFcQef4hbdiCtNUk1qb0H4 +jCr9EEFXOGABpZEk9Shf9E1kJGFJs+r8G48w1NDvO+CwgnCOLLWFq/sVXEUz0eBTEw1 iBwHuF4fBZKV28+acwcAaqg/awPrVuDZjbiYlFh2rZxrkPjjEsq0xa0p9vOJP9wamIlq e9ME25904gjFGtKcvQ8cgf0r2s/GrzGDWmTh5JkF9xbchqIkFXaNUsAfyv7TVqm66Fdx ZS+w== Received: by 10.50.187.225 with SMTP id fv1mr929040igc.28.1333532563115; Wed, 04 Apr 2012 02:42:43 -0700 (PDT) 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.231.164.217 with SMTP id f25csp31252iby; Wed, 4 Apr 2012 02:42:42 -0700 (PDT) Received: by 10.216.132.169 with SMTP id o41mr998220wei.121.1333532561148; Wed, 04 Apr 2012 02:42:41 -0700 (PDT) Received: from mail-wi0-f172.google.com (mail-wi0-f172.google.com [209.85.212.172]) by mx.google.com with ESMTPS id c7si177290wia.20.2012.04.04.02.42.40 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 04 Apr 2012 02:42:41 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.212.172 is neither permitted nor denied by best guess record for domain of daniel.lezcano@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 daniel.lezcano@linaro.org) smtp.mail=daniel.lezcano@linaro.org Received: by wibhj6 with SMTP id hj6so283245wib.13 for ; Wed, 04 Apr 2012 02:42:40 -0700 (PDT) Received: by 10.180.82.136 with SMTP id i8mr3585958wiy.19.1333532560673; Wed, 04 Apr 2012 02:42:40 -0700 (PDT) Received: from localhost.localdomain (AToulouse-159-1-7-136.w90-60.abo.wanadoo.fr. [90.60.242.136]) by mx.google.com with ESMTPS id bx13sm3462265wib.10.2012.04.04.02.42.38 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 04 Apr 2012 02:42:39 -0700 (PDT) From: Daniel Lezcano To: tony@atomide.com, khilman@ti.com Cc: j-pihet@ti.com, santosh.shilimkar@ti.com, rob.lee@linaro.org, linaro-dev@lists.linaro.org, patches@linaro.org Subject: [PATCH 11/17] ARM: OMAP3: cpuidle - remove cpuidle_params_table Date: Wed, 4 Apr 2012 11:42:13 +0200 Message-Id: <1333532539-10298-12-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.7.5.4 In-Reply-To: <1333532539-10298-1-git-send-email-daniel.lezcano@linaro.org> References: <1333532539-10298-1-git-send-email-daniel.lezcano@linaro.org> X-Gm-Message-State: ALoCoQnEaghwXKtIUVCYuL60PfYGrwyrL116BTKhxxlhArgmdjVa9N3b8Rhv/6gW5igKaJoRqOuT We do not longer need the ''cpuidle_params_table' array as we defined the states in the driver and we checked they are all valid. We also remove the structure definition as it is no longer used. Signed-off-by: Daniel Lezcano --- arch/arm/mach-omap2/cpuidle34xx.c | 28 +++------------------------- arch/arm/mach-omap2/pm.h | 12 ------------ 2 files changed, 3 insertions(+), 37 deletions(-) diff --git a/arch/arm/mach-omap2/cpuidle34xx.c b/arch/arm/mach-omap2/cpuidle34xx.c index 3f46e45..cdf1b8f 100644 --- a/arch/arm/mach-omap2/cpuidle34xx.c +++ b/arch/arm/mach-omap2/cpuidle34xx.c @@ -38,36 +38,14 @@ #ifdef CONFIG_CPU_IDLE -/* - * The latencies/thresholds for various C states have - * to be configured from the respective board files. - * These are some default values (which might not provide - * the best power savings) used on boards which do not - * pass these details from the board file. - */ -static struct cpuidle_params cpuidle_params_table[] = { - /* C1 */ - {2 + 2, 5, 1}, - /* C2 */ - {10 + 10, 30, 1}, - /* C3 */ - {50 + 50, 300, 1}, - /* C4 */ - {1500 + 1800, 4000, 1}, - /* C5 */ - {2500 + 7500, 12000, 1}, - /* C6 */ - {3000 + 8500, 15000, 1}, - /* C7 */ - {10000 + 30000, 300000, 1}, -}; -#define OMAP3_NUM_STATES ARRAY_SIZE(cpuidle_params_table) - /* Mach specific information to be recorded in the C-state driver_data */ struct omap3_idle_statedata { u32 mpu_state; u32 core_state; }; + +#define OMAP3_NUM_STATES 7 + struct omap3_idle_statedata omap3_idle_data[OMAP3_NUM_STATES]; struct powerdomain *mpu_pd, *core_pd, *per_pd, *cam_pd; diff --git a/arch/arm/mach-omap2/pm.h b/arch/arm/mach-omap2/pm.h index 5646b80..7856489 100644 --- a/arch/arm/mach-omap2/pm.h +++ b/arch/arm/mach-omap2/pm.h @@ -38,18 +38,6 @@ static inline int omap4_opp_init(void) } #endif -/* - * cpuidle mach specific parameters - * - * The board code can override the default C-states definition using - * omap3_pm_init_cpuidle - */ -struct cpuidle_params { - u32 exit_latency; /* exit_latency = sleep + wake-up latencies */ - u32 target_residency; - u8 valid; /* validates the C-state */ -}; - extern int omap3_pm_get_suspend_state(struct powerdomain *pwrdm); extern int omap3_pm_set_suspend_state(struct powerdomain *pwrdm, int state);