[PATCH] hxd8-resume.patch

Harald Welte laforge at openmoko.org
Wed May 23 02:35:46 CEST 2007

On Tue, May 22, 2007 at 06:20:49PM +0200, Arnaud Patard wrote:
> > – ?,2007-05-22 – 13:50 +0200,Harald Welte ?°:
> >> Hi Matt!
> >> 
> >> The patch seems fine to me (style-wise), however:
> >> 
> >> On Sun, May 20, 2007 at 04:13:20PM +0800, matt_hsu wrote:
> >> > Log:
> >> > 	HXD8: GPG[15:13] must be selected as input for resuming from u-boot.
> >> 
> >> the most important bit is missing: WHY?
> >> 
> > I checked the source, it's result from s3c2410_ts_connect() in
> > s3c2410_ts.c. Even the GPIO configuration (GPGCON) is correct in uboot.
> > TS module would modify these important bits. 
> >
> > But doesn't these bits affect resume logic for GTA01?
> > This caution is not mentioned in S3C2410 datasheet. 
> > That is, GPG[13:15] are not functional pins in NAND boot mode in 2410.
> >
> > So I think this patch should be applied on GTA02 if TS module is
> > included. 
> hmmm... Sorry, but I don't understand. When loaded, the ts driver configures
> the gpio to "ts mode" and doesn't play anymore with them. Nothing to do
> with suspend/resume.

well, not exactly.  Without looking at the documentation again, IIRC the GPG[13:15]
gpio's are used to determine the bootup memory configuration on the
s3c2440.  The resume-from-RAM code in a NAND-only configuration requires
that the first 4k of the bootloader are loaded from NAND into internal
SRAM (steppingstone) for the resume logic to work.

The current s3c2410_ts driver however seems to assume that it is always
only running on s3c2410, not s3c2440.  Thus, it reconfigures GPG12..15

The correct solution to this problem thus is: Put the GPG12..15
initialization in a s3c2410 specific section (runtime, not compile

Matt: plese provide and test a patch against s3c2410_ts.c
- Harald Welte <laforge at openmoko.org>          	        http://openmoko.org/
Software for the world's first truly open Free Software mobile phone

More information about the openmoko-kernel mailing list