All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] sh4:  using PAGE_SIZE during flushing cache related to a
@ 2009-10-13  9:48 Valentin R Sitsikov
  2009-10-16  4:59 ` [PATCH] sh4: using PAGE_SIZE during flushing cache related to a page Paul Mundt
  0 siblings, 1 reply; 2+ messages in thread
From: Valentin R Sitsikov @ 2009-10-13  9:48 UTC (permalink / raw)
  To: linux-sh

Signed-off-by: Valentin Sitdikov <valentin.sitdikov@siemens.com>
---
 arch/sh/mm/cache-sh4.c |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/arch/sh/mm/cache-sh4.c b/arch/sh/mm/cache-sh4.c
index 56dd55a..2cb050d 100644
--- a/arch/sh/mm/cache-sh4.c
+++ b/arch/sh/mm/cache-sh4.c
@@ -27,7 +27,7 @@
  */
 #define MAX_ICACHE_PAGES    32
 
-static void __flush_cache_4096(unsigned long addr, unsigned long phys,
+static void __flush_cache_page(unsigned long addr, unsigned long phys,
                    unsigned long exec_offset);
 
 /*
@@ -82,7 +82,7 @@ static void __uses_jump_to_uncached 
sh4_flush_icache_range(void *args)
     local_irq_restore(flags);
 }
 
-static inline void flush_cache_4096(unsigned long start,
+static inline void _flush_cache_page(unsigned long start,
                     unsigned long phys)
 {
     unsigned long flags, exec_offset = 0;
@@ -96,7 +96,7 @@ static inline void flush_cache_4096(unsigned long start,
         exec_offset = cached_to_uncached;
 
     local_irq_save(flags);
-    __flush_cache_4096(start | SH_CACHE_ASSOC,
+    __flush_cache_page(start | SH_CACHE_ASSOC,
                virt_to_phys(phys), exec_offset);
     local_irq_restore(flags);
 }
@@ -122,8 +122,8 @@ static void sh4_flush_dcache_page(void *arg)
 
         /* Loop all the D-cache */
         n = boot_cpu_data.dcache.way_incr >> 12;
-        for (i = 0; i < n; i++, addr += 4096)
-            flush_cache_4096(addr, phys);
+        for (i = 0; i < n; i++, addr += PAGE_SIZE)
+            _flush_cache_page(addr, phys);
     }
 
     wmb();
@@ -257,7 +257,7 @@ static void sh4_flush_cache_page(void *args)
     }
 
     if (pages_do_alias(address, phys))
-        flush_cache_4096(CACHE_OC_ADDRESS_ARRAY |
+        _flush_cache_page(CACHE_OC_ADDRESS_ARRAY |
             (address & shm_align_mask), phys);
 
     if (vma->vm_flags & VM_EXEC)
@@ -320,7 +320,7 @@ static void sh4_flush_cache_range(void *args)
  * operation (purge/write-back) is selected by the lower 2 bits of
  * 'phys'.
  */
-static void __flush_cache_4096(unsigned long addr, unsigned long phys,
+static void __flush_cache_page(unsigned long addr, unsigned long phys,
                    unsigned long exec_offset)
 {
     int way_count;
@@ -357,7 +357,7 @@ static void __flush_cache_4096(unsigned long addr, 
unsigned long phys,
      * pointless nead-of-loop check for 0 iterations.
      */
     do {
-        ea = base_addr + 4096;
+        ea = base_addr + PAGE_SIZE;
         a = base_addr;
         p = phys;
 
-- 
1.6.3.3


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] sh4:  using PAGE_SIZE during flushing cache related to a page
  2009-10-13  9:48 [PATCH] sh4: using PAGE_SIZE during flushing cache related to a Valentin R Sitsikov
@ 2009-10-16  4:59 ` Paul Mundt
  0 siblings, 0 replies; 2+ messages in thread
From: Paul Mundt @ 2009-10-16  4:59 UTC (permalink / raw)
  To: linux-sh

On Tue, Oct 13, 2009 at 01:48:36PM +0400, Valentin R Sitsikov wrote:
> Signed-off-by: Valentin Sitdikov <valentin.sitdikov@siemens.com>
> ---
> arch/sh/mm/cache-sh4.c |   16 ++++++++--------
> 1 files changed, 8 insertions(+), 8 deletions(-)
> 
This looks ok, but your mail client has unfortunately completely mangled
the patch. Your user-agent string suggests you are using a thunderbird
clone, so please give Documentation/email-clients.txt a read and fixing
up your client so that future patches don't need to be applied by hand.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-10-16  4:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-10-13  9:48 [PATCH] sh4: using PAGE_SIZE during flushing cache related to a Valentin R Sitsikov
2009-10-16  4:59 ` [PATCH] sh4: using PAGE_SIZE during flushing cache related to a page Paul Mundt

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.