Enable update_engine to access OTA package via file descriptor
Due to the restriction of Treble, update_engine cannot access to OTA
packages located on non-core domain area.
(e.g. /data/vendor/upgrade/xxx.zip)
To solve such problem, update_engine needs to have a new interface
which accepts a file descriptor (FD) of OTA package file instead of
its URI and to read package file while updating via FD.
Test: Manual update
Bug: 130209137
Change-Id: Ieb7173dc958ba3eb21af708e616ef7078cd17b3e
diff --git a/binder_bindings/android/os/IUpdateEngine.aidl b/binder_bindings/android/os/IUpdateEngine.aidl
index c0e29f5..cde05be 100644
--- a/binder_bindings/android/os/IUpdateEngine.aidl
+++ b/binder_bindings/android/os/IUpdateEngine.aidl
@@ -26,6 +26,11 @@
in long payload_size,
in String[] headerKeyValuePairs);
/** @hide */
+ void applyPayloadFd(in FileDescriptor fd,
+ in long payload_offset,
+ in long payload_size,
+ in String[] headerKeyValuePairs);
+ /** @hide */
boolean bind(IUpdateEngineCallback callback);
/** @hide */
boolean unbind(IUpdateEngineCallback callback);