[prev in list] [next in list] [prev in thread] [next in thread] 

List:       linux-arm-kernel
Subject:    Re: Arm linux software suspend
From:       junjie cai <junjiec () gmail ! com>
Date:       2005-08-09 11:39:22
Message-ID: ca992f110508090439467ac4b9 () mail ! gmail ! com
[Download RAW message or body]

hi,
i think i forgot something in my patch
(but i cannot show you now because i am at home now).
according to this 2.6.11  kernel source:
http://lxr.linux.no/source/kernel/power/swsusp.c#L867

867 asmlinkage int swsusp_restore(void)
868 {
869         BUG_ON (nr_copy_pages_check != nr_copy_pages);
870         BUG_ON (pagedir_order_check != pagedir_order);
871         
872         /* Even mappings of "global" things (vmalloc) need to be fixed */
873         __flush_tlb_global();
874         return 0;
875 }

before __flush_tlb_global() , there should be a flush_cache_all()
to clean the cache, or after the pgd changed , cache incoherent
problem could happen.
i dont know what is your version's source looks like,
please check it.

and you may want to print the pgd address in save_processor_state & 
restore_processor_state respectively, if they dont match and 
flush_cache_all() is correctly called, then i think there is a great chance
that your flash has some problem.

FYI, my target machines is arm926 + 64M Memory + IDE ...

thanks.

On 8/9/05, Hiroki Kaminaga <kaminaga@sm.sony.co.jp> wrote:
> From: junjie cai <junjiec@gmail.com>
> Subject: Re: Arm linux software suspend
> Date: Tue, 9 Aug 2005 18:24:39 +0900
> 
> > hi,
> > maybe you could try a dummy application as i did,
> > if it failed neither, then there may be something wrong with
> > the storager driver.
> 
> 2.6.11 + swap flash + your patch + your test
> 
> did not work on wakeup from hibernate...
> (attached is a log)
> 
> I looked into your patch, and swsusp_arch_resume() was doing same
> thing as my patch. May be it could be flash problem?
> 
> 
> > according to your OOPS messages,
> > it failed to access 0x8000_XXXX
> > which is not a address in the kernel space.
> > does the OOPS exactly the same
> > for example in the same function, accessing same address
> > or just randomly?
> 
> The virtual address is always similar (0x8000_00xx), but
> pgd is always different, and pc and lr register is always different too.
> 
> What is your target machine look like?
> 
> Regards,
> 
> HK.
> --
> 
> 
> 
> U-Boot 1.1.2 (Feb 22 2005 - 15:44:47)
> 
> U-Boot code: 11080000 -> 110956D4  BSS: -> 11099EA4
> RAM Configuration:
> Bank #0: 10000000 32 MB
> Micron StrataFlash MT28F128J3 device initialized
> Flash: 32 MB
> 
> 
> U-Boot 1.1.2 (Feb 22 2005 - 15:44:47)
> 
> U-Boot code: 11080000 -> 110956D4  BSS: -> 11099EA4
> RAM Configuration:
> Bank #0: 10000000 32 MB
> Micron StrataFlash MT28F128J3 device initialized
> Flash: 32 MB
> 
> 
> U-Boot 1.1.2 (Feb 22 2005 - 15:44:47)
> 
> U-Boot code: 11080000 -> 110956D4  BSS: -> 11099EA4
> RAM Configuration:
> Bank #0: 10000000 32 MB
> Micron StrataFlash MT28F128J3 device initialized
> Flash: 32 MB
> In:    serial
> Out:   serial
> Err:   serial
> Hit any key to stop autoboot: 10  9  8  7  6  5  4  3  2 \
>  1  0 ## Booting image at 10000000 ...
> Image Name:   Linux-2.6.11-alp
> Image Type:   ARM Linux Kernel Image (uncompressed)
> Data Size:    1128440 Bytes =  1.1 MB
> Load Address: 10008000
> Entry Point:  10008000
> Verifying Checksum ... OK
> OK
> 
> Starting kernel ...
> 
> Uncompressing Linux........................................................................... \
> done, booting the kernel. Linux version 2.6.11-alp (kaminaga@nscrel1) (gcc version \
>                 3.4.4) #26 Tue Aug 9 17:40:01 JST 2005
> CPU: ARM926EJ-Sid(wt) [41069263] revision 3 (ARMv5TEJ)
> CPU0: D VIVT write-back cache
> CPU0: I cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets
> CPU0: D cache: 8192 bytes, associativity 4, 32 byte lines, 64 sets
> Machine: TI-OSK
> Memory policy: ECC disabled, Data cache writethrough
> OMAP_DIE_ID_0: 0x488e0419
> OMAP_DIE_ID_1: 0xb9058f79 DIE_REV: 2
> OMAP_PRODUCTION_ID_0: 0xc0aaaafc
> OMAP_PRODUCTION_ID_1: 0x00016b18 JTAG_ID: 0x6b18
> OMAP32_ID_0: 0x03320200
> OMAP32_ID_1: 0x2b58c02f
> JTAG_ID: 0xb58c DIE_REV: 2
> OMAP1611b revision 2 handled as 16xx id: b9058f79488e0419
> Built 1 zonelists
> Kernel command line: console=ttyS0,115200n8 ip=dhcp root=/dev/nfs \
> resume=/dev/mtdblock3 prsv-img Total of 128 interrupts in 4 interrupt banks
> OMAP GPIO hardware version 1.0
> MUX: initialized M7_1610_GPIO62
> PID hash table entries: 256 (order: 8, 4096 bytes)
> OMAP MPU timers initialized
> Console: colour dummy device 80x30
> Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
> Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
> Memory: 32MB = 32MB total
> Memory: 29952KB available (1892K code, 425K data, 108K init)
> Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
> CPU: Testing write buffer coherency: ok
> NET: Registered protocol family 16
> OMAP DMA hardware version 1
> DMA capabilities: 000c0000:00000000:01ff:003f:007f
> Initializing OMAP McBSP system
> USB: hmc 16, usb0 2 wires
> OMAP I2C: Driver ver. 1.3
> tps65010: version 20 Jan 2005
> MUX: initialized N14_1610_UWIRE_CS0
> MUX: initialized N15_1610_UWIRE_CS1
> OMAP OCPI interconnect driver loaded
> Power Management for TI OMAP.
> MUX: initialized T20_1610_LOW_PWR
> NetWinder Floating Point Emulator V0.97 (double precision)
> JFFS2 version 2.2. (C) 2001-2003 Red Hat, Inc.
> omapfb: configured for panel osk
> OMAP LCD controller initialized.
> MUX: initialized PWL
> Console: switching to colour frame buffer device 30x40
> OMAP framebuffer initialized vram=262144
> Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled
> ttyS0 at MMIO 0xfffb0000 (irq = 46) is a ST16654
> ttyS1 at MMIO 0xfffb0800 (irq = 47) is a ST16654
> Trying to free nonexistent resource <fffb9800-fffb981f>
> io scheduler noop registered
> io scheduler anticipatory registered
> io scheduler deadline registered
> io scheduler cfq registered
> RAMDISK driver initialized: 16 RAM disks of 8192K size 1024 blocksize
> loop: loaded (max 8 devices)
> PPP generic driver version 2.4.2
> smc91x.c: v1.1, sep 22 2004 by Nicolas Pitre <nico@cam.org>
> eth0: SMC91C94 (rev 9) at 0xc2852300 IRQ 160 [nowait]
> eth0: Ethernet addr: 00:0e:99:02:05:82
> i2c /dev entries driver
> omap_nor_cs3: Found 1 x16 devices at 0x0 in 16-bit bank
> omap_nor_cs3: Found 1 x16 devices at 0x1000000 in 16-bit bank
> Intel/Sharp Extended Query Table at 0x0031
> Using buffer write method
> cfi_cmdset_0001: Erase suspend on write enabled
> Creating 4 MTD partitions on "omap_nor_cs3":
> 0x00000000-0x00020000 : "bootloader"
> 0x00020000-0x00040000 : "params"
> 0x00040000-0x00240000 : "kernel"
> 0x00240000-0x02000000 : "filesystem"
> mice: PS/2 mouse device common for all mice
> OMAP Keypad Driver
> MUX: initialized P20_1610_GPIO4
> OMAP touchscreen driver initialized
> NET: Registered protocol family 2
> IP: routing cache hash table of 512 buckets, 4Kbytes
> TCP established hash table entries: 2048 (order: 2, 16384 bytes)
> TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
> TCP: Hash tables configured (established 2048 bind 2048)
> NET: Registered protocol family 1
> PM: Reading swsusp image.
> swsusp: Resume From Partition: /dev/mtdblock3
> swsusp: Signature found, resuming
> swsusp: Version: 132619
> swsusp: Num Pages: 8192
> swsusp: UTS Sys: Linux
> swsusp: UTS Node: 192.168.0.43
> swsusp: UTS Release: 2.6.11-alp
> swsusp: UTS Version: #26 Tue Aug 9 17:40:01 JST 2005
> swsusp: UTS Machine: armv5tejl
> swsusp: UTS Domain: (none)
> swsusp: CPUs: 1
> swsusp: Image: 3513 Pages
> swsusp: Pagedir: 1 Pages
> swsusp: Reading pagedir (14 Pages)
> swsusp_pagedir_relocate:begin:pagedir_nosave:c1ca0000
> Relocating pagedir ....::::|
> swsusp_pagedir_relocate:end:pagedir_nosave:c1cf0000
> Reading image data (3513 pages):       0%  1%  2%  3%  4%  \
> 5%  6%  7%  8%  9% 10% 11% 12% 13% 14% \
> 15% 16% 17% 18% 19% 20% 21% 22% 23% 24% \
> 25% 26% 27% 28% 29% 30% 31% 32% 33% 34% \
> 35% 36% 37% 38% 39% 40% 41% 42% 43% 44% \
> 45% 46% 47% 48% 49% 50% 51% 52% 53% 54% \
> 55% 56% 57% 58% 59% 60% 61% 62% 63% 64% \
> 65% 66% 67% 68% 69% 70% 71% 72% 73% 74% \
> 75% 76% 77% 78% 79% 80% 81% 82% 83% 84% \
> 85% 86% 87% 88% 89% 90% 91% 92% 93% 94% \
> 95% 96% 97% 98% 99%100% 3513 done. Reading resume file was \
>                 successful
> PM: Preparing system for restore.
> PM: prepare: Attempting to freeze processes.
> Stopping tasks: ==|
> Freeing memory...  done (0 pages freed)
> PM: prepare: OK.
> pagedir_nosave:c1cf0000
> PM: Restoring saved image.
> Unable to handle kernel paging request at virtual address 80000010
> pgd = c1764000
> [80000010] *pgd=00000000
> Internal error: Oops: 5 [#1]
> Modules linked in:
> CPU: 0
> PC is at __do_irq+0x38/0x88
> LR is at scheduler_tick+0x1c/0x298
> pc : [<c00242bc>]    lr : [<c00388c4>]    Not tainted
> sp : c175bde0  ip : c175bd98  fp : c175be00
> r10: c0245c98  r9 : c175bf78  r8 : c175be50
> r7 : 0000001e  r6 : 00000001  r5 : 20000000  r4 : 80000000
> r3 : 20000000  r2 : 0000ea5f  r1 : 80000093  r0 : 00000001
> Flags: NzCv  IRQs off  FIQs on  Mode SVC_32  Segment user
> Control: 5317F  Table: 11764000  DAC: 00000015
> Process swsusp.sh (pid: 34, stack limit = 0xc175a198)
> Stack: (0xc175bde0 to 0xc175c000)
> bde0: c02462b0 0000001e c175be50 00000004 c175be50 c175be1c c175be04 c0024510
> be00: c0024294 c175a000 fefecb00 ffffffff c175be4c c175be20 c00245b8 c00244b8
> be20: c175be88 c175be30 ffffffff fefecb00 ffffffff 00000004 00000005 c0205240
> be40: c175bea8 c175be50 c0023360 c0024574 00000000 00000000 c020f438 60000013
> be60: 00000000 00000000 c020523c 00000004 00000005 c175bf78 c0205240 c175bea8
> be80: c175be98 c175be98 c005663c c0056648 60000013 ffffffff c024400c c175bec4
> bea0: c175beac c0056b30 c0056600 c10d5000 c0205234 c025500c c175beec c175bec8
> bec0: c00546b8 c0056acc c10d5000 c0205234 00000004 00000004 00000005 c1788780
> bee0: c175bf10 c175bef0 c0054b90 c0054648 00000005 000a0408 c1c804e0 00000000
> bf00: c1c804f4 c175bf20 c175bf14 c00a5580 c0054b28 c175bf4c c175bf24 c00a5878
> bf20: c00a5560 00000005 00000000 c1788780 000a0408 c175a000 c175a000 c175bf78
> bf40: c175bf74 c175bf50 c0074c68 c00a5780 c17887a4 c1788780 c175bf78 00000000
> bf60: 00000000 4019c608 c175bfa4 c175bf78 c0074da0 c0074bb8 00000000 00000000
> bf80: 00000000 00000005 000a0408 4019abd4 00000004 c0023864 00000000 c175bfa8
> bfa0: c00236e0 c0074d64 00000005 c0029f4c 00000001 000a0408 00000005 00000000
> bfc0: 00000005 000a0408 4019abd4 00000000 00000005 00000000 4019c608 00000000
> bfe0: 00000000 befffae4 0000267c 4013ae10 60000010 00000001 41414141 41414141
> Backtrace:
> [<c0024284>] (__do_irq+0x0/0x88) from [<c0024510>] (do_level_IRQ+0x68/0xbc)
> r8 = C175BE50  r7 = 00000004  r6 = C175BE50  r5 = 0000001E
> r4 = C02462B0
> [<c00244a8>] (do_level_IRQ+0x0/0xbc) from [<c00245b8>] (asm_do_IRQ+0x54/0x140)
> r6 = FFFFFFFF  r5 = FEFECB00  r4 = C175A000
> [<c0024564>] (asm_do_IRQ+0x0/0x140) from [<c0023360>] (__irq_svc+0x20/0x80)
> [<c00565f0>] (swsusp_suspend+0x0/0x60) from [<c0056b30>] \
> (pm_suspend_disk+0x74/0x218) r4 = C024400C
> [<c0056abc>] (pm_suspend_disk+0x0/0x218) from [<c00546b8>] (enter_state+0x80/0x2c4)
> r6 = C025500C  r5 = C0205234  r4 = C10D5000
> [<c0054638>] (enter_state+0x0/0x2c4) from [<c0054b90>] (state_store+0x78/0x88)
> [<c0054b18>] (state_store+0x0/0x88) from [<c00a5580>] (subsys_attr_store+0x30/0x3c)
> r8 = C1C804F4  r7 = 00000000  r6 = C1C804E0  r5 = 000A0408
> r4 = 00000005
> [<c00a5550>] (subsys_attr_store+0x0/0x3c) from [<c00a5878>] \
> (sysfs_write_file+0x108/0x14c) [<c00a5770>] (sysfs_write_file+0x0/0x14c) from \
> [<c0074c68>] (vfs_write+0xc0/0x138) [<c0074ba8>] (vfs_write+0x0/0x138) from \
> [<c0074da0>] (sys_write+0x4c/0x74) [<c0074d54>] (sys_write+0x0/0x74) from \
> [<c00236e0>] (ret_fast_syscall+0x0/0x2c) r8 = C0023864  r7 = 00000004  r6 = \
> 4019ABD4  r5 = 000A0408 r4 = 00000005
> Code: e10f3000 e3c33080 e121f003 e1a05006 (e5941010)
> <0>Kernel panic - not syncing: Aiee, killing interrupt handler!
> 
> 
> 

-------------------------------------------------------------------
List admin: http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm-kernel
FAQ:        http://www.arm.linux.org.uk/mailinglists/faq.php
Etiquette:  http://www.arm.linux.org.uk/mailinglists/etiquette.php


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic