Use netlink to set interface up/down in EthernetTracker(1/2)
Currently EthernetTracker uses netd to interact with interfaces, such as
retrieving all interfaces, updating interface configurations etc.
However, the usage of netd can bring some unexpected side effects, such
as clearing v4 address when toggling on/off interface.
This change moves forward with one less usage of netd to use netlink
directly to set interface up/down in EthernetTracker.
This patch adds support in netlink utils to get/set interface flags and
added related unit test.
Bug: 379021505
Test: atest NetworkStaticLibTests
Change-Id: I5f82781663ba340588450cceea55caec4e3991a8
3 files changed