Add an IPC that writes to the tcp_{rmem, wmem}
The system server is controlling the tcp buffer now by writing to
/sys/kernel/ipv4/tcp_{rmem,wmem}_{min,def,max}. Those files are
basically the same as /proc/sys/net/ipv4/tcp_{rmem,wmem} except those
latter ones contain all three values in one file. Netd can directly write
to those files instead of depending on the android specific implementation.
Test: netd_integration_test
Bug: 118572798
Change-Id: I588b48be29ecf61fd5bbf94f97f63738be4eae25
diff --git a/server/NetdNativeService.h b/server/NetdNativeService.h
index 0160cf1..f6d4593 100644
--- a/server/NetdNativeService.h
+++ b/server/NetdNativeService.h
@@ -246,6 +246,10 @@
binder::Status tetherRemoveForward(const std::string& intIface,
const std::string& extIface) override;
+ // tcp_mem-config command
+ binder::Status setTcpRWmemorySize(const std::string& rmemValues,
+ const std::string& wmemValues) override;
+
private:
std::vector<uid_t> intsToUids(const std::vector<int32_t>& intUids);
Permission convertPermission(int32_t permission);