From: Aneesh V Date: Wed, 22 Dec 2010 17:24:51 +0530 Subject: [U-Boot] [PATCH 1/8] arm: make default implementation of cache_flush() weakly linked In-Reply-To: <1293018898-13253-1-git-send-email-aneesh@ti.com> References: <1293018898-13253-1-git-send-email-aneesh@ti.com> Message-ID: <1293018898-13253-2-git-send-email-aneesh@ti.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de make default implementation of cache_flush() weakly linked so that sub-architectures can override it Signed-off-by: Aneesh V --- arch/arm/lib/cache.c | 9 +++------ 1 files changed, 3 insertions(+), 6 deletions(-) diff --git a/arch/arm/lib/cache.c b/arch/arm/lib/cache.c index 30686fe..275b6e1 100644 --- a/arch/arm/lib/cache.c +++ b/arch/arm/lib/cache.c @@ -25,7 +25,7 @@ #include -void flush_cache (unsigned long dummy1, unsigned long dummy2) +void __flush_cache(unsigned long dummy1, unsigned long dummy2) { #if defined(CONFIG_OMAP2420) || defined(CONFIG_ARM1136) void arm1136_cache_flush(void); @@ -38,10 +38,7 @@ void flush_cache (unsigned long dummy1, unsigned long dummy2) /* disable write buffer as well (page 2-22) */ asm("mcr p15, 0, %0, c7, c10, 4" : : "r" (0)); #endif -#ifdef CONFIG_OMAP34XX - void v7_flush_cache_all(void); - - v7_flush_cache_all(); -#endif return; } +void flush_cache(unsigned long dummy1, unsigned long dummy2) + __attribute__((weak, alias("__flush_cache"))); -- 1.7.0.4