Commit graph

114,762 commits

Message SHA1
Android 16.0.0 release 4
-----BEGIN PGP SIGNATURE-----
 
 iF0EABECAB0WIQRDQNE1cO+UXoOBCWTorT+BmrEOeAUCaS5huQAKCRDorT+BmrEO
 eIsnAJ9kJ9OjiHpwigt9XwjTrGcbD1hQ0QCfSw2VHyS9TLyzt7DZsQ3AYU+WVVA=
 =/SH/
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN SSH SIGNATURE-----
 U1NIU0lHAAAAAQAAADMAAAALc3NoLWVkMjU1MTkAAAAgPpdpjxPACTIhnlvYz0GM4BR7FJ
 +rYv3jMbfxNKD3JvcAAAADZ2l0AAAAAAAAAAZzaGE1MTIAAABTAAAAC3NzaC1lZDI1NTE5
 AAAAQHUBff/oLA1TO7KbbZDsBJZmFVcXgFmG+2K3aaKq9F0tiaT1kiNeHdjXpaLI07p344
 TExz9CBvFVft81pJyRBwY=
 -----END SSH SIGNATURE-----

Merge tag 'android-16.0.0_r4' into staging/lineage-23.2_merge-android-16.0.0_r4

Android 16.0.0 release 4

# -----BEGIN PGP SIGNATURE-----
#
# iF0EABECAB0WIQRDQNE1cO+UXoOBCWTorT+BmrEOeAUCaS5huQAKCRDorT+BmrEO
# eIsnAJ9kJ9OjiHpwigt9XwjTrGcbD1hQ0QCfSw2VHyS9TLyzt7DZsQ3AYU+WVVA=
# =/SH/
# -----END PGP SIGNATURE-----
# gpg: Signature made Tue Dec  2 05:49:13 2025 EET
# gpg:                using DSA key 4340D13570EF945E83810964E8AD3F819AB10E78
# gpg: Good signature from "The Android Open Source Project <initial-contribution@android.com>" [ultimate]

# By Yan Yan (203) and others
# Via Automerger Merge Worker (1173) and others
* tag 'android-16.0.0_r4': (1057 commits)
  Use string for CREATE_APP_SPECIFIC_NETWORK permission
  bpf: move MSS calculation under CE check to avoid overhead
  BpfNetworkStats: use `atomic` for ifindex cache when possible
  NetBpfLoad: remove pointless 0 write.
  bpf: remove obsolete isAtLeastR/Sv2/25Q3
  NetBpfLoad: use global `api_level_full` directly in NetBpfLoad
  Log validated underlying network count that's available for VCN underlying network selection
  BpfUtils: fix sdk level detection logic for 25Q3+
  Add RTMGRP_IPV6_IFINFO
  bpf: remove BPFLOADER_MAINLINE_U_QPR3_VERSION
  bpf: move BPFLOADER_MAINLINE_S_VERSION into bpf_map_def.h
  Reduce log level for BluetoothSocket errors
  Bump the min sdk of Tethering
  BpfNetworkStats: apparently RiscV isn't actually a 64-bit architecture.
  KernelUtils.h: isAtLeastKernelVersion(x,y,z) - default 'z' to 0
  bpf_existence_test - update for tcp acc ecn
  bpf: tcpAccECN: eliminate header file and move more fully into netd
  BpfMap: shorten error strings to enable SSO (on 64-bit)
  BpfNetworkStats: enforce that IfaceValue access is lock-free
  NetBpfLoad: use libbpf based on mainline beta flag, part 2
  ...

 Conflicts:
	bpf/headers/include/bpf/KernelUtils.h
	bpf/progs/netd.h

Change-Id: I76a7aadc1405c6621e17f3d1b6b87640d84f5794

Michael Bestas   commited 2025-12-09 22:59:06 +02:00
42374b293f
Revert "Always drop non-VPN ingress in lockdown mode"
This reverts commit 19f95c26ad.

Reason for revert: Conflicts with BP4A.

Change-Id: I9900859136d643bafce00e85c818714bc4e139ef

Michael Bestas   commited 2025-12-09 06:39:21 +02:00
f7f117c4b2
Android 16.0.0 Release 3 (BP3A.250905.014)
-----BEGIN PGP SIGNATURE-----
 
 iF0EABECAB0WIQRDQNE1cO+UXoOBCWTorT+BmrEOeAUCaRO/HAAKCRDorT+BmrEO
 eOs9AJ9Yzz2HpDR3pyRIXhvl4k7bNABGvgCeMg5sU16s0CkFIDbZmOsSo4fswZQ=
 =1o5/
 -----END PGP SIGNATURE-----
gpgsig -----BEGIN SSH SIGNATURE-----
 U1NIU0lHAAAAAQAAADMAAAALc3NoLWVkMjU1MTkAAAAgPpdpjxPACTIhnlvYz0GM4BR7FJ
 +rYv3jMbfxNKD3JvcAAAADZ2l0AAAAAAAAAAZzaGE1MTIAAABTAAAAC3NzaC1lZDI1NTE5
 AAAAQIRFF5B6T8EGhzDN+1dhvomEkctFjdVr5DZnhgnEIvcCEuzO36RzY3DBG9AIL+EejJ
 Z1zz7uAapzWUsyFpbYAQM=
 -----END SSH SIGNATURE-----

Merge tag 'android-16.0.0_r3' into staging/lineage-23.0_merge-android-16.0.0_r3

Android 16.0.0 Release 3 (BP3A.250905.014)

# -----BEGIN PGP SIGNATURE-----
#
# iF0EABECAB0WIQRDQNE1cO+UXoOBCWTorT+BmrEOeAUCaRO/HAAKCRDorT+BmrEO
# eOs9AJ9Yzz2HpDR3pyRIXhvl4k7bNABGvgCeMg5sU16s0CkFIDbZmOsSo4fswZQ=
# =1o5/
# -----END PGP SIGNATURE-----
# gpg: Signature made Wed Nov 12 00:56:28 2025 EET
# gpg:                using DSA key 4340D13570EF945E83810964E8AD3F819AB10E78
# gpg: Good signature from "The Android Open Source Project <initial-contribution@android.com>" [ultimate]

# By Patrick Rohr (91) and others
# Via Android (Google) Code Review (233) and others
* tag 'android-16.0.0_r3': (377 commits)
  Fix netbpfload version info.
  NetBpfLoad: add self-check for bpfGetNext{Prog,Map}Id()
  Add NetworkTemplate get/set transport type methods
  Pass EthernetPort to EthernetNetworkFactory#updateInterfaceLinkState
  Pass EthernetPort to updateInterfaceState
  Remove spurious VisibleForTesting and change visibility to public
  Pass EthernetPort to EthernetNetworkFactory#removeInterface
  Pass EthernetPort to removeInterface
  Pass EthernetPort to stopTrackingInterface
  Add getEthernetPorts and use it in getAllInterfaces
  Rename getClientModeInterfaces to getClientModeInterfacesSorted
  Rename getAvailableInterfaces to getInterfacesSorted
  Pass EthernetPort into NetworkInterfaceState
  Pass EthernetPort into EthernetNetworkFactory#addInterface
  Use multicast socket for group membership
  Test refactoring of DefaultNetworkRematchMetrics
  Fix SatisfiedTime initialization
  DHCPv6 addr reg: parse IA Address option.
  Pass EthernetPort to addInterface
  Change tethering interface to EthernetPort
  ...

 Conflicts:
	bpf/progs/netd.c
	service/src/com/android/server/ConnectivityService.java
	staticlibs/testutils/host/python/apf_test_base.py
	tests/cts/multidevices/apfv4_test.py
	tests/cts/multidevices/apfv6_test.py
	tests/cts/multidevices/run_tests.py
	tests/unit/java/com/android/server/connectivityservice/CSNetworkAgentTest.kt

Change-Id: Ifedf92aee90cbcc55ef8f9652de8b5faff1c30d9

Michael Bestas   commited 2025-11-14 10:29:02 +02:00
c7f07b6a13
Merge cherrypicks of ['googleplex-android-review.googlesource.com/35669132'] into 25Q4-release.
Change-Id: I9c42f46905e3b74a9e5743548eae8f4b35693f38

Android Build Coastguard Worker   commited 2025-09-30 03:58:50 -07:00
f930245ec3
Use string for CREATE_APP_SPECIFIC_NETWORK permission
This allows using the permission in 25Q4 before it becomes a
public API in 26Q2.

Flag: android.net.platform.flags.create_app_specific_network_permission
Test: TH
Bug: 435313135
Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:60f7743f773b05a98e651c953631e93957291bf5
Merged-In: I8d336a588eddf9a027079e208b2b96bb6c163e86
Change-Id: I8d336a588eddf9a027079e208b2b96bb6c163e86

Motomu Utsumi   authored and   Android Build Coastguard Worker   commited 2025-09-30 03:56:13 -07:00
c4fea9d31c
Remove pending BT request when service disconnects
If the PAN service disconnects before the BT iface is available, the BT
TetheringRequest will be stuck pending and prevent any new BT
startTethering attempts. This may happen if the user turns BT tethering
on and turns off BT without connecting to any device.

Fix this by always removing the pending BT request when the PAN service
disconnects.

Flag: EXEMPT minor bugfix

Bug: 420412916
Test: atest TetheringTest, manually verify turning BT tethering on,
turning off BT, and turning BT tethering on again.

Change-Id: I6bc96d6e4016d83af6cfd8e549d474ce651a44fc

Quang Anh Luong   authored and   Bharath   commited 2025-09-25 22:18:38 +05:30
7fe8e5653f
clatd: disable seccomp
Bug: 418375944
Test: TreeHugger
Flag: EXEMPT mainline, bug fix, disable codepath
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I5c36a89c12d4cf836ee1b434b582a6ad2256037e

Maciej Żenczykowski   authored and   Bharath   commited 2025-09-25 21:25:26 +05:30
f94e845024
Fix NetworkAgent 4-way binder interlock
System server        |    Client (e.g. phone)
------------------------------|-----------------------------
                              |
NetworkAgentMessageHandler ←--|--- INetworkAgentRegistry
              ↓               |              ↑
                              |         NetworkAgent
        NetworkAgentInfo      |              ↑
              ↓               |      NetworkAgentHandler
                              |              ↑
         INetworkAgent     ---|--→   NetworkAgentBinder

The simplest artifact is observed by watching the output of
adb shell dumpsys meminfo -d phone | grep 'Proxy Binders'
while turning airplane mode on and off (slowly, to allow the
cell network to connect and disconnect).
This will display the number of binder proxies. Before this, the binder
proxy count increases by 2 with each connection and never goes down (there
is some noise, as proxy objects are sometimes created for other reasons,
and get GC'd eventually). After this, the binder proxy count is always
eventually stable.

Also see b/133174607.

Bug: 400358935
Flag: EXEMPT bugfix
Test: manual, also regression test on the way
Change-Id: I1dcdaec1f3bd42bc2a406c9e9318208f96266bd6

Chalard Jean   authored and   Bharath   commited 2025-09-25 21:18:59 +05:30
58323d3f27
Snap for 14104676 from 68f55e673a to 25Q4-release
Change-Id: I6c1e6b1d56aad0a5475a0bbd7ca93fc6858a1866

Android Build Coastguard Worker   commited 2025-09-15 16:50:50 -07:00
fcc9df03ab
Merge "bpf: move MSS calculation under CE check to avoid overhead" into main
Treehugger Robot   authored and   Android (Google) Code Review   commited 2025-09-15 03:41:29 -07:00
68f55e673a
bpf: move MSS calculation under CE check to avoid overhead
Currently, the MSS-based packet count calculation is performed for
every packet, regardless of whether the IP ECN field indicates CE
(congestion experienced). Since the computed value is only used
when CE is set, this results in unnecessary per-packet processing.

Move the MSS calculation inside the ip_ecn == 0b11 condition so
that it is only executed when a CE mark is actually present. This
reduces overhead on the fast path while preserving correct CE
accounting.

No functional change in CE handling, only an optimization in
execution flow.

Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Sandeep <irlanki.s@samsung.corp-partner.google.com>
Change-Id: I5cae40f914473d9f914c826d50dd91c93e047ccc

Sandeep   authored and   Maciej Żenczykowski   commited 2025-09-15 02:07:44 -07:00
c2c6ce1966
Merge "[Thread] support Thread NetworkRequest" into main
Treehugger Robot   authored and   Android (Google) Code Review   commited 2025-09-14 21:59:51 -07:00
4741933ee8
Snap for 14099086 from a22d4e1061 to 25Q4-release
Change-Id: I40687ca1e6a1ea2951a6d377e9225e2cf1d1a690

Android Build Coastguard Worker   commited 2025-09-13 14:23:04 -07:00
98c16d1361
BpfNetworkStats: use atomic for ifindex cache when possible
Test: TreeHugger
Flag: EXEMPT BUGFIX
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ibc24f079711c36a8bc6ff850fc5b07fb6546b3ae

Maciej Żenczykowski   commited 2025-09-13 05:07:32 -07:00
a22d4e1061
Merge "bpf: remove obsolete isAtLeastR/Sv2/25Q3" into main
Maciej Żenczykowski   authored and   Android (Google) Code Review   commited 2025-09-13 05:06:29 -07:00
8095d6f081
Merge "NetBpfLoad: use global api_level_full directly in NetBpfLoad" into main
Maciej Żenczykowski   authored and   Android (Google) Code Review   commited 2025-09-13 05:06:06 -07:00
8ad4118d66
NetBpfLoad: remove pointless 0 write.
BPF array maps are zero initialized.

Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I11b3b1db8e3fdf5e926c0e164d4c00c7b84684ce

Maciej Żenczykowski   commited 2025-09-13 03:52:34 -07:00
b47900b7c5
bpf: remove obsolete isAtLeastR/Sv2/25Q3
We no longer support mainline on R,
hence checks for R are not required.

We don't want any S vs Sv2 and 25Q2 vs 25Q3 differentiation.

Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I746b404520ccb12fddf02c6956d7cf1824f21bbd

Maciej Żenczykowski   commited 2025-09-13 03:28:18 -07:00
8e730ec9e0
NetBpfLoad: use global api_level_full directly in NetBpfLoad
This change removes the `bpfloader_ver` parameter from several internal functions and replaces its usage with the global `api_level_full` variable, simplifying function signatures.

Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I6165e525d7aa49fbd7d12be0c3ea85015cfc6f3d

Maciej Żenczykowski   commited 2025-09-13 01:57:50 -07:00
68744c4a9a
Merge "Add RTMGRP_IPV6_IFINFO" into main
Xiao Ma   authored and   Android (Google) Code Review   commited 2025-09-12 21:07:08 -07:00
17d48b01af
Merge "[connectivity] support specifying flags in TestableNetworkCallback" into main
Kangping Dong   authored and   Android (Google) Code Review   commited 2025-09-12 18:49:30 -07:00
25a44360f5
Snap for 14095642 from 8d04b03a69 to 25Q4-release
Change-Id: I1b6dc5036ea97c4b3492372705b217c9fa51af25

Android Build Coastguard Worker   commited 2025-09-12 18:24:34 -07:00
09a94541c3
Merge "Log validated underlying network count that's available for VCN underlying network selection" into main
Hnin Naing   authored and   Android (Google) Code Review   commited 2025-09-12 17:52:04 -07:00
264f2de492
Merge "BpfUtils: fix sdk level detection logic for 25Q3+" into main
Maciej Żenczykowski   authored and   Android (Google) Code Review   commited 2025-09-12 17:04:28 -07:00
c231a533ba
Log validated underlying network count that's available for VCN underlying network selection
Flag: EXEMPT METRICS
Test: atest FrameworksVcnTests, CtsVcnTestCases
Bug: 288600040
Change-Id: Ia1b51aa64388bc5c167f3a1081d8683d98fe0bef

Hnin Naing   commited 2025-09-12 22:50:11 +00:00
4ab80490ae
BpfUtils: fix sdk level detection logic for 25Q3+
Test: TreeHugger
Flag: EXEMPT BUGFIX
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I52ee176dc84e9c0e3e1bffd480841f1f1247eaa3

Maciej Żenczykowski   commited 2025-09-12 15:13:46 -07:00
942ea04d1f
Merge "Bump the min sdk of Tethering" into main
Pedro Loureiro   authored and   Android (Google) Code Review   commited 2025-09-12 15:01:57 -07:00
b528f1634b
Merge "Reduce log level for BluetoothSocket errors" into main
Treehugger Robot   authored and   Android (Google) Code Review   commited 2025-09-12 14:07:35 -07:00
f0f91a110a
Merge changes from topics "redact-netcaps", "redact-specifier", "specifier-metrics" into main
* changes:
  [connectivity] rename createWithLocationInfoSanitizedIfNecessaryWhenParceled
  [connectivity] use new redact(RedactionType) for output NetworkSpecifier
  [connectivity] move redaction to createWithLocationInfoSanitizedIfNecessaryWhenParceled
  [connectivity] add permission check on requested NetworkSpecifier
  [connectivity] redact NeworkSpecifier in NetworkCapabilities
  [connectivity] add NetworkCapabilities.RedactionHelper
  [Thread] add REDACT_FOR_THREAD_NETWORK_PRIVILEGED

Kangping Dong   authored and   Android (Google) Code Review   commited 2025-09-12 13:26:22 -07:00
a133acc106
Add RTMGRP_IPV6_IFINFO
This is needed to receive IF_RA_MANAGED and IF_RA_OTHERCONF
notifications from netlink.

See inet6_ifinfo_notify() in addrconf.c.

Test: TH
Flag: NONE yes
Change-Id: I525eef4eb305c08aa2480e91321ea5fd514d4d65

Patrick Rohr   commited 2025-09-12 12:32:56 -07:00
715ef661e4
Merge changes I1ab48e0e,Ie12638a3,I2de4d067 into main
* changes:
  bpf: remove BPFLOADER_MAINLINE_U_QPR3_VERSION
  bpf: move BPFLOADER_MAINLINE_S_VERSION into bpf_map_def.h
  KernelUtils.h: isAtLeastKernelVersion(x,y,z) - default 'z' to 0

Maciej Żenczykowski   authored and   Android (Google) Code Review   commited 2025-09-12 12:07:19 -07:00
5a45c8dc80
bpf: remove BPFLOADER_MAINLINE_U_QPR3_VERSION
This is not used, and it seems unlikely we would ever
want to differentiate based on this.

Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I1ab48e0e4dc7a8979a34509ebc3d901a0bce3840

Maciej Żenczykowski   commited 2025-09-12 12:07:08 -07:00
867eb61b9f
bpf: move BPFLOADER_MAINLINE_S_VERSION into bpf_map_def.h
also while at it renumber things so that in the future
we can autoderive the version from full api level.

Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ie12638a3dcbde9db3e50d1736efa37154b22341c

Maciej Żenczykowski   commited 2025-09-12 12:06:45 -07:00
01640f15a4
Reduce log level for BluetoothSocket errors
This exception is also logged when the other side disconnects gracefully
(because there is no way to distinguish this case using the Bluetooth
APIs). This change reduces the log level to a warning because it is
almost always a red herring.

Test: TH
Flag: NONE yes
Change-Id: I94f20be91ff8481fdd1a50fbbc27200c57885426

Patrick Rohr   commited 2025-09-12 12:02:08 -07:00
81a472014a
Bump the min sdk of Tethering
This is required because we are bumping the min sdk of NetworkStack
which this depends on.

Test: build locally + aapt2 dump badging

Bug: 444168252

Flag: build.RELEASE_DEPRECATE_MAINLINE_R_SUPPORT
Change-Id: Idbff03cdcca9955a4759c19866895f755abedaaf

Pedro Loureiro   commited 2025-09-12 18:34:18 +00:00
48eb28f7ee
BpfNetworkStats: apparently RiscV isn't actually a 64-bit architecture.
I'll follow up with some sort of VTS test to block
RiscV until the compiler/language/libraries etc
can support something like CMPXCHG16B or ldp

Bug: 444697997
Flag: EXEMPT BUGFIX
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I553cffe3c4181842c38baf37258262e7b43b9ca4

Maciej Żenczykowski   commited 2025-09-12 11:16:29 -07:00
c2667777e1
KernelUtils.h: isAtLeastKernelVersion(x,y,z) - default 'z' to 0
This seems to be the most common usecase.

Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I2de4d067b2f20680539cbddb31555864bcf957b1

Maciej Żenczykowski   commited 2025-09-12 10:14:12 -07:00
ee24054e2b
Merge "bpf_existence_test - update for tcp acc ecn" into main
Maciej Żenczykowski   authored and   Android (Google) Code Review   commited 2025-09-12 10:13:41 -07:00
8d04b03a69
Merge "BpfNetworkStats: enforce that IfaceValue access is lock-free" into main
Maciej Żenczykowski   authored and   Android (Google) Code Review   commited 2025-09-12 10:12:48 -07:00
b3edb33500
Merge "bpf: tcpAccECN: eliminate header file and move more fully into netd" into main
Treehugger Robot   authored and   Android (Google) Code Review   commited 2025-09-12 10:03:39 -07:00
cb44b89e11
bpf_existence_test - update for tcp acc ecn
(also tested with a hack to make isAtLeast26Q2 true)

Test: TreeHugger
Flag: EXEMPT TEST_ONLY
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Id1ef5b03cdc27b6d74d6b5bd76692186809e9658

Maciej Żenczykowski   commited 2025-09-12 07:29:24 -07:00
82d68064e1
bpf: tcpAccECN: eliminate header file and move more fully into netd
Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: I3a7a819e1958d7035aa9a046595ada45dce3be21

Maciej Żenczykowski   commited 2025-09-12 07:28:25 -07:00
0e9577bfc5
BpfMap: shorten error strings to enable SSO (on 64-bit)
This should be a performance improvement, as it avoids both memory
allocation (Short String Optimization fits the strings on the heap)
and string formatting.

Additionally should prevent us from triggering an abort()
on OOM as reported on the linked bug:

F DEBUG   : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0000000000000000 (read)
F DEBUG   : Cause: null pointer dereference
F DEBUG   : backtrace:
F DEBUG   :       #00 pc 0000000000000000  <unknown>
F DEBUG   :       #01 pc 000000000001d008  /apex/com.android.tethering/lib64/libbase.so (fmt::v11::vformat(fmt::v11::basic_string_view<char>, fmt::v11::basic_format_args<fmt::v11::context>)+76) (BuildId: d200bca0044b833c9a13a387041b398a)
F DEBUG   :       #02 pc 0000000000007108  /apex/com.android.tethering/lib64/libcom.android.tethering.dns_helper.so (android::bpf::BpfMapRO<unsigned int, UidOwnerValue>::readValue(unsigned int) const+152) (BuildId: b20b032f10bd31bb44f969cef38dcd99)
F DEBUG   :       #03 pc 0000000000006ac8  /apex/com.android.tethering/lib64/libcom.android.tethering.dns_helper.so (android::net::DnsBpfHelper::isUidNetworkingBlocked(unsigned int, bool)+748) (BuildId: b20b032f10bd31bb44f969cef38dcd99)
F DEBUG   :       #04 pc 0000000000008328  /apex/com.android.tethering/lib64/libcom.android.tethering.dns_helper.so (ADnsHelper_isUidNetworkingBlocked.cfi+60) (BuildId: b20b032f10bd31bb44f969cef38dcd99)
F DEBUG   :       #05 pc 00000000001c43b0  /apex/com.android.resolv/lib64/libnetd_resolv.so (android::net::DnsProxyListener::GetAddrInfoHandler::run()+284) (BuildId: 9f306d9e52c85087c00931289aa2d7cd)
F DEBUG   :       #06 pc 00000000001bc888  /apex/com.android.resolv/lib64/libnetd_resolv.so (void* android::netdutils::runAndDelete<android::net::DnsProxyListener::Handler>(void*) (.cfi)+332) (BuildId: 9f306d9e52c85087c00931289aa2d7cd)
F DEBUG   :       #07 pc 0000000000085580  /apex/com.android.runtime/lib64/bionic/libc.so (__pthread_start(void*) (.__uniq.67847048707805468364044055584648682506)+232) (BuildId: 9ea0fa19fb5cc316f79c79f922c5a7dc)
F DEBUG   :       #08 pc 0000000000078248  /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+64) (BuildId: 9ea0fa19fb5cc316f79c79f922c5a7dc)

Bug: 441416613
Test: TreeHugger
Flag: EXEMPT BUGFIX
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ibdae61b0ec67fd77f0be096ff934c8d424ae1e49

Maciej Żenczykowski   commited 2025-09-12 07:12:57 -07:00
8f637b873c
Merge "NetBpfLoad: use libbpf based on mainline beta flag, part 2" into main
Maciej Żenczykowski   authored and   Android (Google) Code Review   commited 2025-09-12 07:10:35 -07:00
4666361ca8
Merge "BpfRingbuf.h: add using-s" into main
Maciej Żenczykowski   authored and   Android (Google) Code Review   commited 2025-09-12 07:09:52 -07:00
c3f84096de
BpfNetworkStats: enforce that IfaceValue access is lock-free
Limited to non-32-bit due to build failures on:
  cf_gwear_x86-trunk_staging-userdebug
  eos-trunk_staging-userdebug
  seluna-next-userdebug
  seluna-trunk_staging-userdebug
  test_suites_x86_64-trunk_staging
  test_suites_x86_64-trunk_staging
  test_suites_x86_64-trunk_staging_coverage

This is unfortunate, as it likely means those platforms are
inefficient and possibly even buggy.

Test: TreeHugger
Flag: EXEMPT TEST_ONLY
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ibf7eaa0707b0ec2e8eb9ac8ee9de8af20b94683b

Maciej Żenczykowski   commited 2025-09-12 07:09:13 -07:00
ef23cee4d7
NetBpfLoad: use libbpf based on mainline beta flag, part 2
Disable shared version of libtetheringflags
  - since the flags are readonly there is no real content to this,
    and it should be statically linked for compile/link time optimization
    (which should basically optimize the entire library out)

Use C++ magic to compile time verify the macro and flag are in sync.

The way this works:

constexpr auto useLibBpf = COM_ANDROID_TETHERING_READONLY_FLAGS_USE_LIBBPF;

^ this basically requires the macro to resolve to true/false, so that 'auto' resolves to 'const bool'

static_assert(std::is_same<decltype(useLibBpf), const bool>::value, "useLibBpf must be a boolean.");

^ which we check here

static_assert(useLibBpf == com::android::tethering::readonly:🎏:use_libbpf(), "useLibBpf flag mismatch");

^ and this then requires the macro and flag to be identical *and* compile time known

Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Id5cd8c7d91b424765d6f469806434b3e9587f074

Maciej Żenczykowski   commited 2025-09-12 04:04:39 -07:00
1c59188cf0
BpfRingbuf.h: add using-s
Test: TreeHugger
Flag: EXEMPT PURE_REFACTOR
Signed-off-by: Maciej Żenczykowski <maze@google.com>
Change-Id: Ie58548451ad21860dbd62776a6e3c4c124c57e00

Maciej Żenczykowski   commited 2025-09-12 03:35:11 -07:00
b9c34ae252
Merge "Add isCaptivePortalLoginFeatureNotChickenedOut" into main
Yuyang Huang   authored and   Android (Google) Code Review   commited 2025-09-12 00:51:14 -07:00
cb1a167e4d
[Thread] support Thread NetworkRequest
Bug: 374037595
Flag: com.android.net.thread.flags.thread_mobile_enabled
Change-Id: Ib13d2a65f7c9693fb998bb98361538e3b6085913

Kangping Dong   commited 2025-09-12 15:06:00 +08:00
43ddfe74fa