Break out some stuff into audio_port.c, so that sndlib_play.c can use it.
Break out some stuff into audio_port.c, so that sndlib_play.c can use it.

RTcmix/RTcmix,RTcmix/RTcmix,RTcmix/RTcmix,RTcmix/RTcmix,RTcmix/RTcmix,RTcmix/RTcmix