Use NativeHandle in MQDescriptor instead of ParcelFileDescriptor
android.hardware.common.fmq.MQDescriptor needs to handle multiple file
descriptors, so changing from ParcelFileDescriptor to
android.hardware.common.NativeHandle.
android.hardware.common.fmq.GrantorDescriptor needs to keep track of the
fdIndex as well.
Bug: 176912570
Test: atest fmq_unit_tests fmq_test
Change-Id: I15f2393e6c420ae5394322b28c4523fa80f7dcc7
diff --git a/tests/msgq/1.0/ITestMsgQ.hal b/tests/msgq/1.0/ITestMsgQ.hal
index bd10237..0cf9c7c 100644
--- a/tests/msgq/1.0/ITestMsgQ.hal
+++ b/tests/msgq/1.0/ITestMsgQ.hal
@@ -41,12 +41,15 @@
*
* @param configureFmq The server sets up a new unsynchronized FMQ if
* this parameter is true.
+ * @param userFd True to initialize the message queue with a user supplied
+ * file descriptor for the ring buffer.
+ * False to let the message queue use a single FD for everything.
*
* @return ret True if successful.
* @return mqDesc This structure describes the unsynchronized FMQ that was
* set up by the service. Client can use it to set up the FMQ at its end.
*/
- getFmqUnsyncWrite(bool configureFmq) generates(bool ret, fmq_unsync<int32_t> mqDesc);
+ getFmqUnsyncWrite(bool configureFmq, bool userFd) generates(bool ret, fmq_unsync<int32_t> mqDesc);
/**
* This method request the service to write into the synchronized read/write