libbinder: RpcConnection: add ID
In preparation to have the server be able to distinguish clients and
clients to be able to dynamically create threads that are assigned to
them.
Future considerations:
- make ID impossible to guess (right now, one client might be able to
get ahold of a thread from a server). We may implement something here
or go for something existing like TLS.
- combine getting max threads and this? will wait until dynamic threads
are actually implemented and we know we need this ID and we're looking
at performance. For now this is a placeholder to enable dynamic client
APIs.
Bug: 185167543
Test: binderRpcTest
Change-Id: If8563c69930c23b9ca91090b4f59ef1f51073f24
diff --git a/libs/binder/RpcWireFormat.h b/libs/binder/RpcWireFormat.h
index cc7cacb..56af0d3 100644
--- a/libs/binder/RpcWireFormat.h
+++ b/libs/binder/RpcWireFormat.h
@@ -48,6 +48,7 @@
enum : uint32_t {
RPC_SPECIAL_TRANSACT_GET_ROOT = 0,
RPC_SPECIAL_TRANSACT_GET_MAX_THREADS = 1,
+ RPC_SPECIAL_TRANSACT_GET_CONNECTION_ID = 2,
};
// serialization is like: