Remove rtems_cache_*_processor_set() functions

The following rtems_cache_*_processor_set() cache manager API functions
are exotic, complex, very hard to use correctly, not used in the RTEMS
code base, and apparently unused by applications.

Close #3622.
This commit is contained in:
Sebastian Huber
2018-11-26 14:04:59 +01:00
parent 6378978940
commit 0a75a4aa65
3 changed files with 7 additions and 215 deletions

View File

@@ -49,97 +49,6 @@
#error "CPU_INSTRUCTION_CACHE_ALIGNMENT is greater than CPU_CACHE_LINE_BYTES"
#endif
#if defined(RTEMS_SMP)
#include <rtems/score/smpimpl.h>
typedef struct {
const void *addr;
size_t size;
} smp_cache_area;
#if defined(CPU_DATA_CACHE_ALIGNMENT)
static void smp_cache_data_flush(void *arg)
{
smp_cache_area *area = arg;
rtems_cache_flush_multiple_data_lines(area->addr, area->size);
}
static void smp_cache_data_inv(void *arg)
{
smp_cache_area *area = arg;
rtems_cache_invalidate_multiple_data_lines(area->addr, area->size);
}
static void smp_cache_data_flush_all(void *arg)
{
rtems_cache_flush_entire_data();
}
static void smp_cache_data_inv_all(void *arg)
{
rtems_cache_invalidate_entire_data();
}
#endif /* defined(CPU_DATA_CACHE_ALIGNMENT) */
void
rtems_cache_flush_multiple_data_lines_processor_set(
const void *addr,
size_t size,
const size_t setsize,
const cpu_set_t *set
)
{
#if defined(CPU_DATA_CACHE_ALIGNMENT)
smp_cache_area area = { addr, size };
_SMP_Multicast_action( setsize, set, smp_cache_data_flush, &area );
#endif
}
void
rtems_cache_invalidate_multiple_data_lines_processor_set(
const void *addr,
size_t size,
const size_t setsize,
const cpu_set_t *set
)
{
#if defined(CPU_DATA_CACHE_ALIGNMENT)
smp_cache_area area = { addr, size };
_SMP_Multicast_action( setsize, set, smp_cache_data_inv, &area );
#endif
}
void
rtems_cache_flush_entire_data_processor_set(
const size_t setsize,
const cpu_set_t *set
)
{
#if defined(CPU_DATA_CACHE_ALIGNMENT)
_SMP_Multicast_action( setsize, set, smp_cache_data_flush_all, NULL );
#endif
}
void
rtems_cache_invalidate_entire_data_processor_set(
const size_t setsize,
const cpu_set_t *set
)
{
#if defined(CPU_DATA_CACHE_ALIGNMENT)
_SMP_Multicast_action( setsize, set, smp_cache_data_inv_all, NULL );
#endif
}
#endif /* defined(RTEMS_SMP) */
/*
* THESE FUNCTIONS ONLY HAVE BODIES IF WE HAVE A DATA CACHE
*/