forked from Imagelibrary/rtems
2007-11-13 Till Straumann <strauman@slac.stanford.edu>
* shared/src/cache.c: moved generic operations (flush/invalidate 1 data line, invalidate 1 inst. line) from #ifdef <cpu_flavor> to general section (all CPUs).
This commit is contained in:
@@ -1,3 +1,9 @@
|
||||
2007-11-13 Till Straumann <strauman@slac.stanford.edu>
|
||||
|
||||
* shared/src/cache.c: moved generic operations
|
||||
(flush/invalidate 1 data line, invalidate 1 inst. line)
|
||||
from #ifdef <cpu_flavor> to general section (all CPUs).
|
||||
|
||||
2007-11-13 Till Straumann <strauman@slac.stanford.edu>
|
||||
|
||||
* shared/src/cache_.h: include <libcpu/cache.h> only
|
||||
|
||||
@@ -62,13 +62,6 @@ void _CPU_cache_disable_data (
|
||||
PPC_Set_HID0( value );
|
||||
}
|
||||
|
||||
void _CPU_cache_invalidate_1_data_line(
|
||||
const void * _address )
|
||||
{
|
||||
register const void *__address = _address;
|
||||
asm volatile ( "dcbi 0,%0" :: "r"(__address) : "memory" );
|
||||
}
|
||||
|
||||
void _CPU_cache_invalidate_entire_data (
|
||||
void )
|
||||
{
|
||||
@@ -98,13 +91,6 @@ void _CPU_cache_unfreeze_data (
|
||||
PPC_Set_HID0( value );
|
||||
}
|
||||
|
||||
void _CPU_cache_flush_1_data_line(
|
||||
const void * _address )
|
||||
{
|
||||
register const void *__address = _address;
|
||||
asm volatile ( "dcbf 0,%0" :: "r" (__address) : "memory" );
|
||||
}
|
||||
|
||||
void _CPU_cache_flush_entire_data (
|
||||
void )
|
||||
{
|
||||
@@ -131,12 +117,6 @@ void _CPU_cache_disable_instruction (
|
||||
PPC_Set_HID0( value );
|
||||
}
|
||||
|
||||
void _CPU_cache_invalidate_1_instruction_line(
|
||||
const void * _address )
|
||||
{
|
||||
register const void *__address = _address;
|
||||
asm volatile ( "icbi 0,%0" :: "r" (__address) : "memory");
|
||||
}
|
||||
|
||||
void _CPU_cache_invalidate_entire_instruction (
|
||||
void )
|
||||
@@ -237,4 +217,26 @@ void _CPU_cache_disable_instruction ( void )
|
||||
}
|
||||
#endif
|
||||
|
||||
void _CPU_cache_invalidate_1_data_line(
|
||||
const void * _address )
|
||||
{
|
||||
register const void *__address = _address;
|
||||
asm volatile ( "dcbi 0,%0" :: "r"(__address) : "memory" );
|
||||
}
|
||||
|
||||
void _CPU_cache_flush_1_data_line(
|
||||
const void * _address )
|
||||
{
|
||||
register const void *__address = _address;
|
||||
asm volatile ( "dcbf 0,%0" :: "r" (__address) : "memory" );
|
||||
}
|
||||
|
||||
|
||||
void _CPU_cache_invalidate_1_instruction_line(
|
||||
const void * _address )
|
||||
{
|
||||
register const void *__address = _address;
|
||||
asm volatile ( "icbi 0,%0" :: "r" (__address) : "memory");
|
||||
}
|
||||
|
||||
/* end of file */
|
||||
|
||||
Reference in New Issue
Block a user