Skip to content

Commit

Permalink
m68k: cache: add an empty stub functions for invalidate/flush dcache
Browse files Browse the repository at this point in the history
Since some driver like ohci, lcd used dcache functions. But m68k don't
implement the invalidate_dcache_range()/flush_dcache_range() functions.

To avoid compiling errors this patch adds an weak empty stub function
for all m68k cpu.

Also each cpu can implement its own implementation. If not implemented
then by default is using an empty function.

Signed-off-by: Josh Wu <[email protected]>
Acked-by: Angelo Dureghello <[email protected]>
  • Loading branch information
JoshWu authored and trini committed Aug 13, 2015
1 parent 057c220 commit 4dbe4b1
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions arch/m68k/lib/cache.c
Original file line number Diff line number Diff line change
Expand Up @@ -132,3 +132,12 @@ void dcache_invalid(void)
__asm__ __volatile__("movec %0, %%cacr"::"r"(temp));
#endif
}

__weak void invalidate_dcache_range(unsigned long start, unsigned long stop)
{
/* An empty stub, real implementation should be in platform code */
}
__weak void flush_dcache_range(unsigned long start, unsigned long stop)
{
/* An empty stub, real implementation should be in platform code */
}

0 comments on commit 4dbe4b1

Please sign in to comment.