From: Pavel Machek <pavel@suse.cz>
To: "Rafael J. Wysocki" <rjw@sisk.pl>, linux-stable@vger.kernel.org
Cc: Russell King <rmk+lkml@arm.linux.org.uk>,
Stanislav Brabec <utx@penguin.cz>,
kernel list <linux-kernel@vger.kernel.org>,
rpurdie@rpsys.net, lenz@cs.wisc.edu, Dirk@opfer-online.de,
arminlitzel@web.de, pavel.urban@ct.cz,
metan@atrey.karlin.mff.cuni.cz, thommycheck@gmail.com,
milan@ucw.cz
Subject: [Patch 2.6.27] fix booting on Sharp Zaurus c3000
Date: Sun, 26 Oct 2008 19:41:09 +0100 [thread overview]
Message-ID: <20081026184108.GB1847@ucw.cz> (raw)
In-Reply-To: <200810250001.04835.rjw@sisk.pl>
Hi!
> > > Thanks for the effort, but it looks like it did not make it, right?
> >
> > Correct - Linus was unpredictable and released 2.6.27 that evening,
> > four days early giving me no time to push the fix to him.
> >
> > However, it's gone in as part of the first ARM merge, so should be in
> > -rc1.
>
> Is it in -stable? if not, is it considered as -stable material?
Yes, I guess it should go to stable.
commit 69fc7eed5f56bce15b239e5110de2575a6970df4
Author: Dmitry Baryshkov <dbaryshkov@gmail.com>
Date: Thu Oct 9 16:58:13 2008 +0100
[ARM] 5300/1: fixup spitz reset during boot
Some machines don't have the pullup/down on their reset
pin, so configuring the reset generating pin as input makes
them reset immediately. Fix that by making reset pin direction
configurable.
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Pavel Machek <pavel@suse.cz>
diff --git a/arch/arm/mach-pxa/include/mach/reset.h b/arch/arm/mach-pxa/include/mach/reset.h
index 9489a48..7b8842c 100644
--- a/arch/arm/mach-pxa/include/mach/reset.h
+++ b/arch/arm/mach-pxa/include/mach/reset.h
@@ -10,9 +10,12 @@
extern unsigned int reset_status;
extern void clear_reset_status(unsigned int mask);
-/*
- * register GPIO as reset generator
+/**
+ * init_gpio_reset() - register GPIO as reset generator
+ *
+ * @gpio - gpio nr
+ * @output - set gpio as out/low instead of input during normal work
*/
-extern int init_gpio_reset(int gpio);
+extern int init_gpio_reset(int gpio, int output);
#endif /* __ASM_ARCH_RESET_H */
diff --git a/arch/arm/mach-pxa/reset.c b/arch/arm/mach-pxa/reset.c
index 31d7885..1b2af57 100644
--- a/arch/arm/mach-pxa/reset.c
+++ b/arch/arm/mach-pxa/reset.c
@@ -20,7 +20,7 @@ static void do_hw_reset(void);
static int reset_gpio = -1;
-int init_gpio_reset(int gpio)
+int init_gpio_reset(int gpio, int output)
{
int rc;
@@ -30,9 +30,12 @@ int init_gpio_reset(int gpio)
goto out;
}
- rc = gpio_direction_input(gpio);
+ if (output)
+ rc = gpio_direction_output(gpio, 0);
+ else
+ rc = gpio_direction_input(gpio);
if (rc) {
- printk(KERN_ERR "Can't configure reset_gpio for input\n");
+ printk(KERN_ERR "Can't configure reset_gpio\n");
gpio_free(gpio);
goto out;
}
diff --git a/arch/arm/mach-pxa/spitz.c b/arch/arm/mach-pxa/spitz.c
index 9b4f24c..524f656 100644
--- a/arch/arm/mach-pxa/spitz.c
+++ b/arch/arm/mach-pxa/spitz.c
@@ -618,7 +618,7 @@ static void spitz_restart(char mode)
static void __init common_init(void)
{
- init_gpio_reset(SPITZ_GPIO_ON_RESET);
+ init_gpio_reset(SPITZ_GPIO_ON_RESET, 1);
pm_power_off = spitz_poweroff;
arm_pm_restart = spitz_restart;
diff --git a/arch/arm/mach-pxa/tosa.c b/arch/arm/mach-pxa/tosa.c
index 9f3ef9e..130e37e 100644
--- a/arch/arm/mach-pxa/tosa.c
+++ b/arch/arm/mach-pxa/tosa.c
@@ -781,7 +781,7 @@ static void __init tosa_init(void)
gpio_set_wake(MFP_PIN_GPIO1, 1);
/* We can't pass to gpio-keys since it will drop the Reset altfunc */
- init_gpio_reset(TOSA_GPIO_ON_RESET);
+ init_gpio_reset(TOSA_GPIO_ON_RESET, 0);
pm_power_off = tosa_poweroff;
arm_pm_restart = tosa_restart;
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
next prev parent reply other threads:[~2008-10-27 9:05 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-09 9:19 2.6.27-rc8 regression on arm: kernel will no longer boot on Sharp Zaurus c-3000 Pavel Machek
2008-10-09 12:00 ` Stanislav Brabec
2008-10-09 14:23 ` Russell King
2008-10-15 10:17 ` Pavel Machek
2008-10-15 11:39 ` Russell King
2008-10-24 22:01 ` Rafael J. Wysocki
2008-10-26 18:41 ` Pavel Machek [this message]
2008-10-27 16:25 ` [Patch 2.6.27] fix booting on Sharp Zaurus c3000 Randy Dunlap
2008-10-28 6:42 ` Andrew Morton
2008-10-28 8:44 ` Russell King
2008-10-28 9:24 ` Alan Cox
2008-10-28 17:56 ` Randy Dunlap
2008-11-07 18:43 ` [PATCH] arm: fix kernel-doc syntax Randy Dunlap
2008-10-28 18:24 ` [Patch 2.6.27] fix booting on Sharp Zaurus c3000 Pavel Machek
2008-10-28 20:05 ` Randy Dunlap
2008-10-09 16:28 ` 2.6.27-rc8 regression on arm: kernel will no longer boot on Sharp Zaurus c-3000 Russell King
2008-10-12 8:53 ` Pavel Machek
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=20081026184108.GB1847@ucw.cz \
--to=pavel@suse.cz \
--cc=Dirk@opfer-online.de \
--cc=arminlitzel@web.de \
--cc=lenz@cs.wisc.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-stable@vger.kernel.org \
--cc=metan@atrey.karlin.mff.cuni.cz \
--cc=milan@ucw.cz \
--cc=pavel.urban@ct.cz \
--cc=rjw@sisk.pl \
--cc=rmk+lkml@arm.linux.org.uk \
--cc=rpurdie@rpsys.net \
--cc=thommycheck@gmail.com \
--cc=utx@penguin.cz \
/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
all inboxes | Powered by JetHome®