refactor AudioRecord and AudioFlinger openRecord()

Refactor the mechanism used by audio record tracks to query and
attach to an input mixer/stream in audio flinger. This will:
 - reduce the number of binder transactions needed to create a record track
 - move sample rate, framecount and flags validations to audio server side
 - move audio session allocation to audio server side
 - prepare restriction of certain binder transactions to audioserver only

Also:
 - renamed openRecord() to createRecord() for consistency with AudioTrack
 - make AudioRecord mStatus update consistent when calling default
 contructor + set() or constructor with arguments
 - make AudioClient, CreateTrackXXX and  CreateRecordXXX classes derive
 from Parcelable
 - restore audio session ID validity check in AudioFlinger::createTrack()

Test: CTS tests: AudioRecordTest, AudioRecordingConfigurationTest, AudioPreProcessingTest
Test: manual test for capture use cases: camcorder, OK Google, VoIP calls
Change-Id: I72edaa7ddef1da11c77df21e88378e3aa9012d58
diff --git a/services/audioflinger/TrackBase.h b/services/audioflinger/TrackBase.h
index d4ce0b4..a3ea756 100644
--- a/services/audioflinger/TrackBase.h
+++ b/services/audioflinger/TrackBase.h
@@ -192,7 +192,7 @@
                                     // where for AudioTrack (but not AudioRecord),
                                     // 8-bit PCM samples are stored as 16-bit
     const size_t        mFrameCount;// size of track buffer given at createTrack() or
-                                    // openRecord(), and then adjusted as needed
+                                    // createRecord(), and then adjusted as needed
 
     const audio_session_t mSessionId;
     uid_t               mUid;