From: eric.y.miao@gmail.com (Eric Miao)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] pxa: Remove unused MFP LPM definition
Date: Tue, 27 Apr 2010 11:16:44 +0800 [thread overview]
Message-ID: <s2yf17812d71004262016xb120ea1j2d0d7dd14ebd3d28@mail.gmail.com> (raw)
In-Reply-To: <4BD64FF1.2090007@gmail.com>
On Tue, Apr 27, 2010 at 10:46 AM, David Hunter <hunterd42@gmail.com> wrote:
> MFP_LPM_INPUT snuck in some time ago as part of "[PATCH] pxa: better
> MFP low power state support for pxa25x/pxa27x", but went unused in the
> final revision of said patch. Using it on PXA3xx would cause an
> out-of-bounds access of mfpr_table[]. Let's remove it before someone
> gets hurt.
>
Instead of removing this potentially useful low power mode pin status, what
about the following patch:
commit f5d406d50f924c82ddf469f120fa420f0499d901
Author: Eric Miao <eric.y.miao@gmail.com>
Date: Tue Apr 27 11:14:24 2010 +0800
[ARM] pxa: allow MFP_LPM_INPUT to be explicitly specified
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
diff --git a/arch/arm/mach-pxa/mfp-pxa2xx.c b/arch/arm/mach-pxa/mfp-pxa2xx.c
index e5b7921..1d1419b 100644
--- a/arch/arm/mach-pxa/mfp-pxa2xx.c
+++ b/arch/arm/mach-pxa/mfp-pxa2xx.c
@@ -81,6 +81,7 @@ static int __mfp_config_gpio(unsigned gpio, unsigned long c)
PGSR(bank) &= ~mask;
is_out = 1;
break;
+ case MFP_LPM_INPUT:
case MFP_LPM_DEFAULT:
break;
default:
diff --git a/arch/arm/plat-pxa/mfp.c b/arch/arm/plat-pxa/mfp.c
index be58f9f..b77e018 100644
--- a/arch/arm/plat-pxa/mfp.c
+++ b/arch/arm/plat-pxa/mfp.c
@@ -110,6 +110,7 @@ static const unsigned long mfpr_lpm[] = {
MFPR_LPM_PULL_LOW,
MFPR_LPM_PULL_HIGH,
MFPR_LPM_FLOAT,
+ MFPR_LPM_INPUT,
};
/* mapping of MFP_PULL_* definitions to MFPR_PULL_* register bits */
next prev parent reply other threads:[~2010-04-27 3:16 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-27 2:46 [PATCH] pxa: Remove unused MFP LPM definition David Hunter
2010-04-27 3:16 ` Eric Miao [this message]
2010-05-04 22:18 ` David Hunter
2010-05-05 0:23 ` Eric Miao
2010-05-05 0:41 ` Marek Vasut
-- strict thread matches above, loose matches on Subject: below --
2010-04-08 22:00 David Hunter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=s2yf17812d71004262016xb120ea1j2d0d7dd14ebd3d28@mail.gmail.com \
--to=eric.y.miao@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).