r3604 - branches/src/target/kernel/2.6.24.x/patches

laforge at sita.openmoko.org laforge at sita.openmoko.org
Thu Dec 6 14:10:02 CET 2007


Author: laforge
Date: 2007-12-06 14:09:59 +0100 (Thu, 06 Dec 2007)
New Revision: 3604

Modified:
   branches/src/target/kernel/2.6.24.x/patches/gta01-jbt6k74.patch
Log:
jbt6k74: Resume into right mode
This patch fixes the resume behaviour. The driver always resumes into
VGA mode. This was fine before adding QVGA mode, but it breaks now.

This patch seaves the mode during suspend and resmues into the saved
mode.

Signed-off-by: Stefan Schmidt <stefan at openmoko.org>


Modified: branches/src/target/kernel/2.6.24.x/patches/gta01-jbt6k74.patch
===================================================================
--- branches/src/target/kernel/2.6.24.x/patches/gta01-jbt6k74.patch	2007-12-06 13:08:01 UTC (rev 3603)
+++ branches/src/target/kernel/2.6.24.x/patches/gta01-jbt6k74.patch	2007-12-06 13:09:59 UTC (rev 3604)
@@ -29,7 +29,7 @@
 ===================================================================
 --- /dev/null
 +++ linux-2.6/drivers/spi/jbt6k74.c
-@@ -0,0 +1,646 @@
+@@ -0,0 +1,648 @@
 +/* Linux kernel driver for the tpo JBT6K74-AS LCM ASIC
 + *
 + * Copyright (C) 2006-2007 by OpenMoko, Inc.
@@ -149,7 +149,7 @@
 +
 +#define JBT_TX_BUF_SIZE
 +struct jbt_info {
-+	enum jbt_state state;
++	enum jbt_state state, last_state;
 +	u_int16_t tx_buf[8];
 +	struct spi_device *spi_dev;
 +	u_int16_t reg_cache[0xEE];
@@ -625,6 +625,8 @@
 +	switch (state.event) {
 +	case PM_EVENT_SUSPEND:
 +	case 3:
++		/* Save mode for resume */
++		jbt->last_state = jbt->state;
 +		jbt6k74_enter_state(jbt, JBT_STATE_DEEP_STANDBY);
 +		return 0;
 +	default:
@@ -637,7 +639,7 @@
 +	struct jbt_info *jbt = dev_get_drvdata(&spi->dev);
 +	DEBUGP("entering\n");
 +
-+	jbt6k74_enter_state(jbt, JBT_STATE_NORMAL);
++	jbt6k74_enter_state(jbt, jbt->last_state);
 +	jbt6k74_display_onoff(jbt, 1);
 +
 +	return 0;





More information about the commitlog mailing list