aboutsummaryrefslogtreecommitdiff
path: root/arch/arm/plat-s3c24xx/neo1973_pm_gps.c
diff options
context:
space:
mode:
authorAndy Green <andy@openmoko.com>2008-11-19 17:09:58 +0000
committerAndy Green <agreen@pads.home.warmcat.com>2008-11-19 17:09:58 +0000
commitc3a78e6ea03689bc097ed449c9ae2597d94f3277 (patch)
tree7018af34ebc032d7b3d38a796a14c3fc1c254af7 /arch/arm/plat-s3c24xx/neo1973_pm_gps.c
parentcb559a9ddbd67883ec2e328ed69f9ad68768b4de (diff)
use-gta02-glamo-mci-sd-dynamic-clock.patch
This patch uses the new glamo-mci slow clock ratio patch in order to dynamically reduce SD Card clock rate when the GPS unit is powered on GTA02. Signed-off-by: Andy Green <andy@openmoko.com>
Diffstat (limited to 'arch/arm/plat-s3c24xx/neo1973_pm_gps.c')
-rw-r--r--arch/arm/plat-s3c24xx/neo1973_pm_gps.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/arch/arm/plat-s3c24xx/neo1973_pm_gps.c b/arch/arm/plat-s3c24xx/neo1973_pm_gps.c
index 8cd583d75fa..a21b7639b17 100644
--- a/arch/arm/plat-s3c24xx/neo1973_pm_gps.c
+++ b/arch/arm/plat-s3c24xx/neo1973_pm_gps.c
@@ -39,6 +39,12 @@ struct neo1973_pm_gps_data {
static struct neo1973_pm_gps_data neo1973_gps;
+int neo1973_pm_gps_is_on(void)
+{
+ return neo1973_gps.power_was_on;
+}
+EXPORT_SYMBOL_GPL(neo1973_pm_gps_is_on);
+
/* This is the 2.8V supply for the RTC crystal, the mail clock crystal and
* the input to VDD_RF */
static void gps_power_2v8_set(int on)
@@ -265,6 +271,9 @@ static int gps_power_1v5_get(void)
/* This is the POWERON pin */
static void gps_pwron_set(int on)
{
+
+ neo1973_gps.power_was_on = !!on;
+
#ifdef CONFIG_MACH_NEO1973_GTA01
if (machine_is_neo1973_gta01())
neo1973_gpb_setpin(GTA01_GPIO_GPS_PWRON, on);
@@ -492,9 +501,6 @@ static DEVICE_ATTR(power_sequence, 0644, power_sequence_read,
static int gta01_pm_gps_suspend(struct platform_device *pdev,
pm_message_t state)
{
-
- neo1973_gps.power_was_on = gps_pwron_get();
-
#ifdef CONFIG_MACH_NEO1973_GTA01
if (machine_is_neo1973_gta01()) {
/* FIXME */