diff options
| -rw-r--r-- | arch/arm/include/asm/outercache.h | 14 | ||||
| -rw-r--r-- | arch/arm/mm/Kconfig | 6 |
2 files changed, 20 insertions, 0 deletions
diff --git a/arch/arm/include/asm/outercache.h b/arch/arm/include/asm/outercache.h index c8571cbb5574..25f76bae57ab 100644 --- a/arch/arm/include/asm/outercache.h +++ b/arch/arm/include/asm/outercache.h | |||
| @@ -25,6 +25,9 @@ struct outer_cache_fns { | |||
| 25 | void (*inv_range)(unsigned long, unsigned long); | 25 | void (*inv_range)(unsigned long, unsigned long); |
| 26 | void (*clean_range)(unsigned long, unsigned long); | 26 | void (*clean_range)(unsigned long, unsigned long); |
| 27 | void (*flush_range)(unsigned long, unsigned long); | 27 | void (*flush_range)(unsigned long, unsigned long); |
| 28 | #ifdef CONFIG_OUTER_CACHE_SYNC | ||
| 29 | void (*sync)(void); | ||
| 30 | #endif | ||
| 28 | }; | 31 | }; |
| 29 | 32 | ||
| 30 | #ifdef CONFIG_OUTER_CACHE | 33 | #ifdef CONFIG_OUTER_CACHE |
| @@ -58,4 +61,15 @@ static inline void outer_flush_range(unsigned long start, unsigned long end) | |||
| 58 | 61 | ||
| 59 | #endif | 62 | #endif |
| 60 | 63 | ||
| 64 | #ifdef CONFIG_OUTER_CACHE_SYNC | ||
| 65 | static inline void outer_sync(void) | ||
| 66 | { | ||
| 67 | if (outer_cache.sync) | ||
| 68 | outer_cache.sync(); | ||
| 69 | } | ||
| 70 | #else | ||
| 71 | static inline void outer_sync(void) | ||
| 72 | { } | ||
| 73 | #endif | ||
| 74 | |||
| 61 | #endif /* __ASM_OUTERCACHE_H */ | 75 | #endif /* __ASM_OUTERCACHE_H */ |
diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index c4ed9f93f646..88a24de55aaf 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig | |||
| @@ -736,6 +736,12 @@ config NEEDS_SYSCALL_FOR_CMPXCHG | |||
| 736 | config OUTER_CACHE | 736 | config OUTER_CACHE |
| 737 | bool | 737 | bool |
| 738 | 738 | ||
| 739 | config OUTER_CACHE_SYNC | ||
| 740 | bool | ||
| 741 | help | ||
| 742 | The outer cache has a outer_cache_fns.sync function pointer | ||
| 743 | that can be used to drain the write buffer of the outer cache. | ||
| 744 | |||
| 739 | config CACHE_FEROCEON_L2 | 745 | config CACHE_FEROCEON_L2 |
| 740 | bool "Enable the Feroceon L2 cache controller" | 746 | bool "Enable the Feroceon L2 cache controller" |
| 741 | depends on ARCH_KIRKWOOD || ARCH_MV78XX0 | 747 | depends on ARCH_KIRKWOOD || ARCH_MV78XX0 |
