From patchwork Tue Apr 24 14:05:33 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 8081 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 CB86C23E1D for ; Tue, 24 Apr 2012 14:06:06 +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 91552A1892D for ; Tue, 24 Apr 2012 14:06:06 +0000 (UTC) Received: by mail-iy0-f180.google.com with SMTP id e36so1457668iag.11 for ; Tue, 24 Apr 2012 07:06:06 -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=gIVjqi+lSAYuMT04ElKbC85MEO7Mm0YGgwXfOqC2fb4=; b=eVElbt9++49NrOsJ/78vJ2/mJ7stIO08BZbIniuoWLbflPYJC0KudNBDmh8i1Qr+Bg Y/HcNPQq7Y8dGk1VjYpPaGDxQWkfpzs7/Dl2S1sgJFzjwjiwH3O7EHgeywJURMir6EkU K8MK+orR/BWXGHXfVuXSWyJ8hJ0CgdYU1ctV+Nn32ViryLKk2QyUoHB6ewzxtWk1ER5R ohNFnQW20+GIE3RH3H8yBMFEcr7Xb9Q71nCQrsueO4Wa3lbSopjZ3GSvHsnRhUWdvVWs JskQX6CoO4WTQ3Dh8X+XQbFLvzEsJDfBXIw3vr0edxr3Fe/hB05OrDlbP9JvV6epvSTY Z/Tg== Received: by 10.43.49.201 with SMTP id vb9mr2080004icb.35.1335276366332; Tue, 24 Apr 2012 07:06:06 -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.137.198 with SMTP id x6csp183997ibt; Tue, 24 Apr 2012 07:06:05 -0700 (PDT) Received: by 10.14.94.142 with SMTP id n14mr3264391eef.99.1335276364917; Tue, 24 Apr 2012 07:06:04 -0700 (PDT) Received: from mail-we0-f178.google.com (mail-we0-f178.google.com [74.125.82.178]) by mx.google.com with ESMTPS id w28si19326272weq.138.2012.04.24.07.06.04 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 24 Apr 2012 07:06:04 -0700 (PDT) Received-SPF: neutral (google.com: 74.125.82.178 is neither permitted nor denied by best guess record for domain of daniel.lezcano@linaro.org) client-ip=74.125.82.178; Authentication-Results: mx.google.com; spf=neutral (google.com: 74.125.82.178 is neither permitted nor denied by best guess record for domain of daniel.lezcano@linaro.org) smtp.mail=daniel.lezcano@linaro.org Received: by mail-we0-f178.google.com with SMTP id a13so605477wer.37 for ; Tue, 24 Apr 2012 07:06:04 -0700 (PDT) Received: by 10.180.92.71 with SMTP id ck7mr31808417wib.2.1335276364402; Tue, 24 Apr 2012 07:06:04 -0700 (PDT) Received: from localhost.localdomain (AToulouse-159-1-17-225.w92-134.abo.wanadoo.fr. [92.134.64.225]) by mx.google.com with ESMTPS id fl2sm47121222wib.2.2012.04.24.07.06.02 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 24 Apr 2012 07:06:03 -0700 (PDT) From: Daniel Lezcano To: santosh.shilimkar@ti.com, jean.pihet@newoldbits.com, khilman@ti.com, tony@atomide.com Cc: linux-omap@vger.kernel.org, linaro-dev@lists.linaro.org, linux-arm-kernel@lists.infradead.org, patches@linaro.org Subject: [PATCH 12/18][V3] ARM: OMAP3: cpuidle - remove cpuidle_params_table Date: Tue, 24 Apr 2012 16:05:33 +0200 Message-Id: <1335276339-11135-13-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.7.5.4 In-Reply-To: <1335276339-11135-1-git-send-email-daniel.lezcano@linaro.org> References: <1335276339-11135-1-git-send-email-daniel.lezcano@linaro.org> X-Gm-Message-State: ALoCoQny4oJVepERGT1pMrBMVEppsvHwOb8kYJRT+YkGBX1y8m9CcGY6MKg7Rf3GD8yriw29DWun 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 Reviewed-by: Jean Pihet --- 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 29b4f87..a82a887 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);