Changeset 4089


Ignore:
Timestamp:
02/21/08 05:04:39 (5 years ago)
Author:
werner
Message:

First part of suspend-prelim2.bin by Matt Hsu, with some adaptations.
(The system can get into suspend when gsmd starts up.)

arch/arm/plat-s3c24xx/neo1973_pm_gsm.c (gta01_gsm_suspend, gta01_gsm_resume):

set GTA02_GPIO_nDL_GSM during suspend (if on GTA02)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/src/target/kernel/2.6.24.x/patches/gta02-power_control.patch

    r4088 r4089  
    1313 #define DRVMSG "FIC Neo1973 Bluetooth Power Management" 
    1414  
    15 @@ -27,14 +29,30 @@ 
     15@@ -27,14 +29,30 @@ static ssize_t bt_read(struct device *de 
    1616                       char *buf) 
    1717 { 
     
    5151  
    5252        return strlcpy(buf, "0\n", 3); 
    53 @@ -48,20 +66,37 @@ 
     53@@ -48,20 +66,37 @@ static ssize_t bt_write(struct device *d 
    5454        unsigned long on = simple_strtoul(buf, NULL, 10); 
    5555  
     
    100100  
    101101        return count; 
    102 @@ -107,9 +142,16 @@ 
     102@@ -107,9 +142,16 @@ static int __init gta01_bt_probe(struct  
    103103 { 
    104104        dev_info(&pdev->dev, DRVMSG ": starting\n"); 
     
    140140        int gpio_ngsm_en; 
    141141        struct console *con; 
    142 @@ -54,8 +61,16 @@ 
     142@@ -54,8 +61,16 @@ static ssize_t gsm_read(struct device *d 
    143143                if (s3c2410_gpio_getpin(GTA01_GPIO_MODEM_RST)) 
    144144                        goto out_1; 
     
    159159  
    160160        return strlcpy(buf, "0\n", 3); 
    161 @@ -70,32 +85,65 @@ 
     161@@ -70,32 +85,65 @@ static ssize_t gsm_write(struct device * 
    162162  
    163163        if (!strcmp(attr->attr.name, "power_on")) { 
     
    232232  
    233233        return count; 
    234 @@ -134,7 +182,7 @@ 
     234@@ -111,6 +159,9 @@ static int gta01_gsm_suspend(struct plat 
     235        /* GPIO state is saved/restored by S3C2410 core GPIO driver, so we 
     236         * don't need to do anything here */ 
     237  
     238+       /* disable DL GSM to prevent jack_insert becoming flaoting */ 
     239+       if (machine_is_neo1973_gta02()) 
     240+               s3c2410_gpio_setpin(GTA02_GPIO_nDL_GSM, 1); 
     241        return 0; 
     242 } 
     243  
     244@@ -124,6 +175,8 @@ static int gta01_gsm_resume(struct platf 
     245        if (s3c2410_gpio_getpin(GTA01_GPIO_MODEM_ON) && gta01_gsm.con) 
     246                console_stop(gta01_gsm.con); 
     247  
     248+       if (machine_is_neo1973_gta02()) 
     249+               s3c2410_gpio_setpin(GTA02_GPIO_nDL_GSM, 0); 
     250        return 0; 
     251 } 
     252 #else 
     253@@ -134,7 +187,7 @@ static int gta01_gsm_resume(struct platf 
    235254 static struct attribute *gta01_gsm_sysfs_entries[] = { 
    236255        &dev_attr_power_on.attr, 
     
    241260 }; 
    242261  
    243 @@ -158,8 +206,17 @@ 
     262@@ -158,8 +211,17 @@ static int __init gta01_gsm_probe(struct 
    244263                gta01_gsm.gpio_ngsm_en = GTA01Bv2_GPIO_nGSM_EN; 
    245264                s3c2410_gpio_setpin(GTA01v3_GPIO_nGSM_EN, 0); 
     
    260279                         system_rev); 
    261280                break; 
    262 @@ -175,9 +232,13 @@ 
     281@@ -175,9 +237,13 @@ static int __init gta01_gsm_probe(struct 
    263282                break; 
    264283        } 
Note: See TracChangeset for help on using the changeset viewer.