From: <bob...@us...> - 2006-10-01 10:20:35
|
Revision: 613 http://svn.sourceforge.net/hackndev/?rev=613&view=rev Author: bobofdoom Date: 2006-10-01 03:20:27 -0700 (Sun, 01 Oct 2006) Log Message: ----------- palmld: Standby mode now working again (in 2.6.17). Modified Paths: -------------- linux4palm/linux/trunk/arch/arm/mach-pxa/palmld/palmld_pm.c Modified: linux4palm/linux/trunk/arch/arm/mach-pxa/palmld/palmld_pm.c =================================================================== --- linux4palm/linux/trunk/arch/arm/mach-pxa/palmld/palmld_pm.c 2006-10-01 09:41:54 UTC (rev 612) +++ linux4palm/linux/trunk/arch/arm/mach-pxa/palmld/palmld_pm.c 2006-10-01 10:20:27 UTC (rev 613) @@ -17,8 +17,8 @@ { /* wake up on */ - PWER |= PWER_RTC | PWER_GPIO12; - PFER |= PWER_RTC; + PWER |= PWER_GPIO12; + //PFER |= PWER_RTC; PRER |= PWER_GPIO12; /* USB, in theory this can even wake us from deep sleep */ @@ -26,10 +26,12 @@ PFER |= PWER_GPIO3; PRER |= PWER_GPIO3; - PCFR = PCFR_GPR_EN | PCFR_OPDE; + /* disable GPIO reset, palm bootloader will hang us */ + //PCFR |= PCFR_GPR_EN | PCFR_OPDE; + PCFR &= PCFR_GPR_EN; /* as set by POS */ - PGSR0 = 0x00020000; + /*PGSR0 = 0x00020000; PGSR1 = 0x00000000; PGSR2 = 0x01004000; PGSR3 = 0x00421380; @@ -38,10 +40,11 @@ PGSR3 |= (1<<7) | (1<<8) | (1<<9); PSLR = 0xff400000; - + */ //PKWR |= GPIO_bit(0) | GPIO_bit(12) | GPIO_bit(3) | (1<<17); - PKSR = 0xffffffff; // clear + //PKSR = 0xffffffff; // clear + /* addr_a0200000 = phys_to_virt(0xa0200000); addr_a0200004 = phys_to_virt(0xa0200004); addr_a0200008 = phys_to_virt(0xa0200008); @@ -49,25 +52,33 @@ save_a0200000 = *addr_a0200000; save_a0200004 = *addr_a0200004; save_a0200008 = *addr_a0200008; - + */ /* c: e3a00121 mov r0, #1073741832 ; 0x40000008 10: e280060f add r0, r0, #15728640 ; 0xf00000 14: e590f000 ldr pc, [r0] */ - + + /* *addr_a0200000 = 0xe3a00121; // mov r0, #0x40000008 *addr_a0200004 = 0xe280060f; // add r0, r0, #0xf00000 *addr_a0200008 = 0xe590f000; // ldr pc, [r0] + */ + PSPR = 0; /* should cause Palm bootloader to allow us to reboot */ return; } static void palmld_pxa_ll_pm_resume(void) { + /* *addr_a0200000 = save_a0200000; *addr_a0200004 = save_a0200004; *addr_a0200008 = save_a0200008; + */ + + /* re-enable GPIO reset */ + PCFR |= PCFR_GPR_EN; } struct pxa_ll_pm_ops palmld_ll_pm_ops = { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |