The remote editor allows to read/write from/to a remote file. This
change:
- Adds new binder API `writeFile`.
- Update fd_server to serve a read/writable fd. Read operation is done
through the existing read API when applicable.
- Adds `RemoteFileEditor` as a binder client for both read and write.
Bug: 171279640
Test: adb shell exec 9<>/data/local/tmp/output fd_server --rw-fds 9
Test: with changes in fusefs.rs, saw file changed correctly (md5sum)
Change-Id: I78ef198ee8a3a0f2d99717dc0c00fccde757f3de
fd_server provides a binder service (currently local binder since remote
binder is not ready). The server starts with FDs specified in the
command line flags (and supposedly opened FDs passed from the parent
process).
fd_server is supposed to run in Android to provide backing file to
authfs.
Test: # Start the server to serve the file. Read from the client.
adb shell 'exec
9</system/bin/sh
8</data/local/tmp/input.4m
7</data/local/tmp/input.4m.merkle_dump
6</data/local/tmp/input.4m.fsv_sig
fd_server --ro-fds 9 --ro-fds 8:7:6'`
Bug: 171280169
Change-Id: Ide68f23d7177b726ffd48ef960276bd8cf5e5846