Fix IMountService transaction ids.
- (IBinder.FIRST_CALL_TRANSACTION=1) is added to the specified
transaction codes during binder generation. Correct the
IMountService transaction ids taking this into account.
- Update interface descriptors in MountService related native code.
- Add proxy implementations for IMountServiceListener and
IMountShutdownObserver.
Bug: 30977067
Test: Verified that calls from native code to IMountService system
service are working and listeners in native code can get the
callbacks correctly.
Change-Id: I9bef9a8113e92d8b36e963bd961ac858acac3f2a
diff --git a/libs/storage/IMountShutdownObserver.cpp b/libs/storage/IMountShutdownObserver.cpp
index a74a768..6114d4a 100644
--- a/libs/storage/IMountShutdownObserver.cpp
+++ b/libs/storage/IMountShutdownObserver.cpp
@@ -23,6 +23,16 @@
TRANSACTION_onShutDownComplete = IBinder::FIRST_CALL_TRANSACTION,
};
+class BpMountShutdownObserver: public BpInterface<IMountShutdownObserver> {
+public:
+ explicit BpMountShutdownObserver(const sp<IBinder>& impl)
+ : BpInterface<IMountShutdownObserver>(impl) { }
+
+ virtual void onShutDownComplete(const int32_t /* statusCode */) {}
+};
+
+IMPLEMENT_META_INTERFACE(MountShutdownObserver, "android.os.storage.IMountShutdownObserver")
+
status_t BnMountShutdownObserver::onTransact(
uint32_t code, const Parcel& data, Parcel* reply, uint32_t flags)
{