|Skip Navigation Links|
|Exit Print View|
|man pages section 9: DDI and DKI Driver Entry Points Oracle Solaris 11 Information Library|
- synchronize DMA caches for an audio engine
#include <sys/audio/audio_driver.h> void prefix_sync(void *state, unsigned nframes)
pointer to driver supplied soft state
integer value indicating the number of frames that have been either sent or received and need to be synchronized in the cache since the last time audio_engine_sync() was called
Solaris DDI specific (Solaris DDI)
The audio_engine_sync() function is used as a hook to request device drivers to perform DMA cache synchronization of the buffer.
Drivers should call ddi_dma_sync(9F) when this function is called. The direction used for the operation can be determined by the driver. Engines performing playback must use DDI_DMA_SYNC_FORDEV, and engines performing record must use DDI_DMA_SYNC_FORKERNEL.
Drivers are responsible for maintaining a running index to keep track of the offset where cache synchronization is needed, but the framework indicates how many frames need to be synchronized in the nframes parameter. Many drivers elect to synchronize the entire buffer for simplicity.
The index should be reset to 0 whenever audio_engine_start(9E) is called.
This function may be called from user or interrupt context.
See attributes(5) for descriptions of the following attributes: