fifo: isolate atomic and futex operations

Now all atomic and futex operations occur in fifo_index.cpp.
This implements these TODOs:
 - Abstract out atomic operations to audio_utils_fifo_index
 - Replace friend by setter and getter, and abstract the futex
This is one of a series of CLs to isolate the dependencies.

Test: builds OK on Android, host Linux, and host macOS
Change-Id: Ic4ec46d472c583dce8525f11ed8cb1db89928d30
5 files changed