From patchwork Sat Oct 27 09:17:54 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 1654731 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork1.kernel.org (Postfix) with ESMTP id DC6043FD4F for ; Sat, 27 Oct 2012 09:22:34 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TS2ZU-0008VY-08; Sat, 27 Oct 2012 09:20:48 +0000 Received: from mail-pb0-f49.google.com ([209.85.160.49]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1TS2Xc-0007HD-Hm for linux-arm-kernel@lists.infradead.org; Sat, 27 Oct 2012 09:18:54 +0000 Received: by mail-pb0-f49.google.com with SMTP id xa7so2999974pbc.36 for ; Sat, 27 Oct 2012 02:18:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :in-reply-to:references:x-gm-message-state; bh=w3DqR0xgv+tJ3qmIYuFAF+8iRtUek5pWZgcHbGeIBEU=; b=HtbLcGtvLLBtXEhbB7TSnT/mMkL4jI8ADcb8epqxgqMEw0KJdTUiwPFUZGfIyKLNxI K3ph0d5Ffnon5H7GspPz9iDAG9K30m7rF4CfPrTXxAs06yTJ5hSPwH66M7ocvbsaxIaY BqJRVJW6uaWMMilOUCw9zT7OciOpoPMJAyRWhNVVwJdO6D9bypfzBLZloc1RvknMq7q+ fHQaN695uNs8yqSo1qUkgJ0BMIBvgvdxjRD/1y3AfVD096i+QwV4F2pAlJxnS1R3kfjZ xkhV9a+1fZs43Bt66h84uuuQrgZ70BjE0we3Wayyuh67BRbmgqOrtGz8oT2DljxEds7a PxVw== Received: by 10.68.239.198 with SMTP id vu6mr77630565pbc.109.1351329532281; Sat, 27 Oct 2012 02:18:52 -0700 (PDT) Received: from localhost ([122.167.99.215]) by mx.google.com with ESMTPS id iu8sm2551435pbc.71.2012.10.27.02.18.49 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 27 Oct 2012 02:18:51 -0700 (PDT) From: Viresh Kumar To: linus.walleij@linaro.org Subject: [PATCH 9/9] pinctrl: SPEAr1340: Add clcd sleep mode pin configuration Date: Sat, 27 Oct 2012 14:47:54 +0530 Message-Id: <3e57c43f3f0572de7bec94020a4b59058541210c.1351329224.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 1.7.12.rc2.18.g61b472e In-Reply-To: References: In-Reply-To: References: X-Gm-Message-State: ALoCoQnfa9124u6McMWzOQhgZOVDMDZX8NwfJXjy1FbkusxQmPbFos75TBvEWyIsQnobI5aCDTLq X-Spam-Note: CRM114 invocation failed X-Spam-Score: -0.1 (/) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-0.1 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.160.49 listed in list.dnswl.org] 2.5 SUSPICIOUS_RECIPS Similar addresses in recipient list -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Vipul Kumar Samar , Viresh Kumar , spear-devel@list.st.com, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org From: Vipul Kumar Samar CLCD pads must be configured differently for sleep mode. This patch adds support for clcd_sleep_pingroup. Signed-off-by: Vipul Kumar Samar Signed-off-by: Viresh Kumar --- drivers/pinctrl/spear/pinctrl-spear1340.c | 39 ++++++++++++++++++++++++++++++- 1 file changed, 38 insertions(+), 1 deletion(-) diff --git a/drivers/pinctrl/spear/pinctrl-spear1340.c b/drivers/pinctrl/spear/pinctrl-spear1340.c index 3963675..0606b8c 100644 --- a/drivers/pinctrl/spear/pinctrl-spear1340.c +++ b/drivers/pinctrl/spear/pinctrl-spear1340.c @@ -1692,7 +1692,43 @@ static struct spear_pingroup clcd_pingroup = { .nmodemuxs = ARRAY_SIZE(clcd_modemux), }; -static const char *const clcd_grps[] = { "clcd_grp" }; +/* Disable cld runtime to save panel damage */ +static struct spear_muxreg clcd_sleep_muxreg[] = { + { + .reg = PAD_SHARED_IP_EN_1, + .mask = ARM_TRACE_MASK | MIPHY_DBG_MASK, + .val = 0, + }, { + .reg = PAD_FUNCTION_EN_5, + .mask = CLCD_REG4_MASK | CLCD_AND_ARM_TRACE_REG4_MASK, + .val = 0x0, + }, { + .reg = PAD_FUNCTION_EN_6, + .mask = CLCD_AND_ARM_TRACE_REG5_MASK, + .val = 0x0, + }, { + .reg = PAD_FUNCTION_EN_7, + .mask = CLCD_AND_ARM_TRACE_REG6_MASK, + .val = 0x0, + }, +}; + +static struct spear_modemux clcd_sleep_modemux[] = { + { + .muxregs = clcd_sleep_muxreg, + .nmuxregs = ARRAY_SIZE(clcd_sleep_muxreg), + }, +}; + +static struct spear_pingroup clcd_sleep_pingroup = { + .name = "clcd_sleep_grp", + .pins = clcd_pins, + .npins = ARRAY_SIZE(clcd_pins), + .modemuxs = clcd_sleep_modemux, + .nmodemuxs = ARRAY_SIZE(clcd_sleep_modemux), +}; + +static const char *const clcd_grps[] = { "clcd_grp", "clcd_sleep_grp" }; static struct spear_function clcd_function = { .name = "clcd", .groups = clcd_grps, @@ -1893,6 +1929,7 @@ static struct spear_pingroup *spear1340_pingroups[] = { &sdhci_pingroup, &cf_pingroup, &xd_pingroup, + &clcd_sleep_pingroup, &clcd_pingroup, &arm_trace_pingroup, &miphy_dbg_pingroup,