]> err.no Git - linux-2.6/commitdiff
[ARM] 3551/1: S3C24XX: PM code failes to compile with CONFIG_DCACHE_WRITETHROUGH
authorBen Dooks <ben-linux@fluff.org>
Sun, 18 Jun 2006 15:21:51 +0000 (16:21 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Sun, 18 Jun 2006 15:21:51 +0000 (16:21 +0100)
Patch from Ben Dooks

If CONFIG_CPU_DCACHE_WRITETHOUGH is set, then the
S3C24XX PM code fails to compile, as there is no
need to flush the D-cache, the flush function
arm920_flush_kern_cache_all() is not compiled.

Fix the code to not use this if the config is set.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/mach-s3c2410/pm.c
arch/arm/mach-s3c2410/sleep.S

index fe57d966a34d126b62194950ea10882f6c3a20fc..43e9a550a203d762e4f2f0dbcf013ad5b9d70787 100644 (file)
@@ -58,7 +58,11 @@ unsigned long s3c_pm_flags;
 
 /* cache functions from arch/arm/mm/proc-arm920.S */
 
+#ifndef CONFIG_CPU_DCACHE_WRITETHROUGH
 extern void arm920_flush_kern_cache_all(void);
+#else
+static void arm920_flush_kern_cache_all(void) { }
+#endif
 
 #define PFX "s3c24xx-pm: "
 
index 73de2eaca22a1c136db339177eb95d1acc4a7610..5f6761ed96b207cdcae72642b693a52c0ca94242 100644 (file)
@@ -66,7 +66,9 @@ ENTRY(s3c2410_cpu_suspend)
        @@ flush the caches to ensure everything is back out to
        @@ SDRAM before the core powers down
 
+#ifndef CONFIG_CPU_DCACHE_WRITETHROUGH
        bl      arm920_flush_kern_cache_all
+#endif
 
        @@ prepare cpu to sleep