Age | Commit message (Collapse) | Author |
|
This allows callers to create a tap interface instead of a tun.
Also specify IFF_NO_PI in order to make it easier for users of
this class to read data from the tun. No existing users actually
check the data, so this is safe.
Bug: 150736748
Test: atest netd_integration_test
Change-Id: Ic2e46bb864978b969ae5c1b8c2bdc5379d298f5a
|
|
/dev/net/tun"
|
|
(this is the upstream default location of the 'tun' special device)
Test: build, atest
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ie834a16264dc1188aa9f3fb40cb5e0e5643737cc
|
|
This is presumed to maybe hopefully fix a race condition test failure
in BinderTest#ClatdStartStop...
Based on testing we go from 35 in 1000 failres to 0 in 1000.
Test: build, atest
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I16eab409c39f5c9711d322c5df611f7bcb46c4c9
|
|
ifc_add_address() returns -errno on error, and doesn't necessarily
set 'errno' (for example if error came in via netlink message).
Test: builds
Bug: 142764715
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I9151649785d7c3cc4316d0e35e9b83dfa0d5053e
|
|
Resolves:
system/netd/tests/tun_interface.cpp:148:19: warning: 'find' called with a string literal consisting of a single character; consider using the more effective overload accepting a character [performance-faster-string-find]
Test: builds
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I1e86cc386859b8a7c20c651d5efd25501dc45e53
|
|
Currently TunInterface assumes that IP addresses are created
immediately as soon as ifc_add_address returns. However, IPv6
addresses, even if created with IFA_F_NODAD or optimistic DAD,
are not created immediately and are not actually usable when the
netlink ACK returns.
Ensure tests aren't flaky by waiting for RTM_NEWADDR for the
address after creating it.
Test: system/netd/tests/runtests.sh
Change-Id: I5db5e25b24329ecbe953b592997b6c1358722c5c
|
|
Use another buffer to log unsolicited event.
Test: built, flashed, booted
Test: 1. manual test datacall/wifi work
2. manual test tethering work
3. run cts StrictModeTest pass
4. manual test data alert work
5. manual idletimer work
Change-Id: I1e4ed360b0c9d60c14bc7f0ffdf578fc557d3643
|
|
Test: built, flashed, booted
system/netd/tests/runtests.sh passes
Change-Id: I14e80377bc1b7c08993c3cf8fbf2b6fd0f99f4ba
|
|
Test: built, flashed, booted
system/netd/tests/runtests.sh passes
Change-Id: I7db81136dfaa581d4257a05aad64059dc0cd7976
|
|
Fixes -Wzero-as-null-pointer-constant warning.
Test: m
Bug: 68236239
Change-Id: I226a0599db4f7c3557e55cade7869d00bd314949
|
|
- Support more than one TunInterface per process by adding some
randomness to the interface name.
- Export include files so it can be used from other directories.
- Add a method to get the interface index.
Bug: 73032258
Test: netd_unit_test passes, netd_integration_test has no new failures
Change-Id: I0968cd394e18e51aec6b48f07ac626ba2496160f
|
|
Bug: 28362720
Test: test-only change. netd_{unit,integration}_test pass.
Change-Id: I89f7c922ae8f8a550db58938dacff92390cc1d0f
|