#include <cafe/os.h> BOOL LCEnableDMA( void );
TRUE is return on success.
FALSE on failure.
Enables the calling thread to perform locked-cache DMA.
A thread doing DMA cannot migrate to another core.
LCEnableDMA validates that the current
thread has core affinity only for the core that it is currently executing on.
DMA transactions are not cache-coherent. Before performing DMAs, the data may need to be flushed or invalidated from the L1d-L2 cache hierarchy.
Test for a locked cache DMA completion by checking the locked-cache DMA
queue length (for example,
LCWaitDMAQueue). When there are multiple locked-cache DMA
requests between different execution contexts (threads) is it difficult to
track a context's lock-cache DMA completion. This function is an attempt to
reduce this complexity with a somewhat stricter execution model.
Since the OS wants to use locked-cache DMA to optimize some core OS functions, a defined function helps to coordinate locked-cache DMA usage between the OS and an application.
|Background, Cores 0 & 1||In applications, do not call this function from Core 0 or 1 when in the background.|
|Callbacks||Do not call this function from any callback function.|
2013-05-08 Automated cleanup pass.
LCGetAllocatableSize. Removed LCLoadDMAASync and LCStoreDMAASync.
2011-03-15 Initial version.