58 Commits

Author SHA1 Message Date
markchien
6d06f6d51a [Tether13] Move TetheringManager into framework
Move tethering out of ConnectivityService. All client would
use TetheringManager to talk with TetheringService directly.

Bug: 144320246
Test: -build, flash, boot
      -atest TetheringTests

Change-Id: Ib051bea724a256f9c4572b566e46ae7b9c4abe6e
Merged-In: Ib051bea724a256f9c4572b566e46ae7b9c4abe6e
2019-12-19 20:53:06 +08:00
Jiyong Park
e86e89acff Add filegroups for services.* libraries
... in preparation for creating a stub library from services.jar

Bug: 139391334
Test: m

Exempt-From-Owner-Approval: cherry-pick from internal

Merged-In: Ifd6cfc77acf2284804a2f64011c2733b5c222369
(cherry picked from commit bae2e907966dce0cb3eaf3e3a81cca4364b7d941)
Change-Id: Ifd6cfc77acf2284804a2f64011c2733b5c222369
2019-12-11 15:55:33 +09:00
markchien
0df2ebc43d [Tether07] Migrate Tethering into module
Now tethering would be run in dedicated service.
TetheringManager is the interface used to communicate with
TetheringService. The new call flow would be: ConnectivityManager
-> ConnectivityService -> TetheringManager -> TetheringService.
Note: the return value of #tether(), #untether() and #setUsbTethering()
APIs would always be no error. Client can use #getLastTetherError()
or #getTetheredIfaces or listen tether state change to check
status of corresponding interface.

Bug: 136040414
Bug: 144742179
Test: -build, flash, boot
      -atest TetheringTests
      -atest FrameworksNetTests

Change-Id: I7e78c0e0a3e70f940a749ba2a39ece7c7ec5b9b3
Merged-In: I7e78c0e0a3e70f940a749ba2a39ece7c7ec5b9b3
2019-11-30 10:03:08 +00:00
markchien
d8676d99ff [Tether07] Clean up build rule for libtetheroffloadjni
- Statically include android.hardware.tetheroffload.config@1.0,
  libcutils and their dependency library.
- Use shared-lib if there is NDK or NDK-compliant version
- Remove android.hardware.tetheroffload.control-V1.0-java from
  service.core because it is already statically built in tethering apk

Bug: 143195885
Test: -build, flash, boot
Change-Id: Ic082045bc04d3989f7f095c7a499bc0d943e4031
Merged-In: Ic082045bc04d3989f7f095c7a499bc0d943e4031
2019-11-30 09:57:36 +00:00
Steven Moreland
5af46952b2 Remove vibrator@1.4
Since this HAL was converted to AIDL.

Bug: 141828236
Test: boot, use vibrator
Change-Id: I0835dcecf7e6a3a4b5b01675df2a36ca8e6cd7a7
2019-11-18 20:10:34 -08:00
atrost
1a9455046c Move android.compat.annotation package out of libcore
Test: m + flash
Bug: 142650523
Change-Id: I1321195c8724485a90b162b32c3c8549dbd11c42
2019-11-11 15:10:57 +00:00
Treehugger Robot
80c3a5db12 Merge "Fix netd_aidl_interface compatible problem" 2019-11-01 02:23:31 +00:00
Harpreet "Eli" Sangha
89ffc2d327 Vibrator Service: Support Async Callback APIs
Bug: 136220871
Test: TBD
Change-Id: Ia639dd01081218db0bc3029316a58a03b9d4d927
(cherry picked from commit 7a4f1d23eaa5c55d84d8316bb531f7be03b08efb)
Merged-In: Ia639dd01081218db0bc3029316a58a03b9d4d927
2019-10-31 09:51:09 -07:00
markchien
11467288c6 Fix netd_aidl_interface compatible problem
Both of services.net and services.core statically link
netd_aidl_interface. But they use different version.
Since services.core already include service.net, removing
netd_aidl_interface from service.core.

Bug: 143560726
Bug: 139280289
Test: -build, flash, boot
      -Off/On tethering

Change-Id: Ifa83880ee7ee88ed67f8b638228ef1b0887e201e
2019-10-31 20:50:11 +08:00
markchien
f303c5a881 [Tether04] Migrate EntitlementManager into module
Bug: 136040414
Test: -build, flash, boot
      -atest TetheringTests
      -atest FrameworksNetTests

Change-Id: Ifdfc6cd95377351c37946a146b60896f07ece59d
Merged-In: Ifdfc6cd95377351c37946a146b60896f07ece59d
2019-10-30 11:06:28 +00:00
markchien
08cc03051a [Tether03] Migrate IpServer into module
Add IpServer which is used to serve ip configuration, dhcp, dns proxy
and nat for downstream interface.

Bug: 136040414
Test: -build, flash, boot
      -atest TetheringTests
      -atest FrameworksNetTests

Change-Id: I23652ae0b9509abe7d38da96d523eb22ab00a343
2019-10-24 14:20:52 +08:00
markchien
a6ba54d59d [Tether02] Migrate TetheringConfiguration into module
TetheringConfiguration is a utility class to encapsulate the various
configuration elements.

Bug: 136040414
Test: -build, flash, boot
      -atest TetheringTests

Change-Id: I9434ab213bc5e0fca59f14a6c8cea554abefc3a4
2019-10-24 14:00:05 +08:00
Luke Huang
a3ddee80fd Merge "Support enable/disable dns forwarding of dnsmasq when start tethering"
am: 6fecb94292

Change-Id: I8f5c67fa1e045c9fd4a5e7a753df285d1111c1d2
2019-08-28 06:06:44 -07:00
Luke Huang
b0d52464f1 Support enable/disable dns forwarding of dnsmasq when start tethering
Bug: 128782815
Test: built, flashed, booted
Change-Id: Ic6ee985b42cbe77e8f2208fba62108604fc7bbcf
2019-08-20 20:42:13 +08:00
atrost
fee45aa4dc Move IPlatformCompat.aidl definition to framework.jar
There are non-app process usecases in framework code that need to have
access to this API.
Created a new package android.compat in frameworks/base/core following
previous definition of android.compat.Compatibility for app processes
(http://cs/android/libcore/luni/src/main/java/android/compat/Compatibility.java).

Bug: 137769727
Test: m
Change-Id: Ifc1b97ad40c2baf65a86169e101acfa72e3aae5f
Merged-In: Ifc1b97ad40c2baf65a86169e101acfa72e3aae5f
2019-08-14 16:47:18 +01:00
atrost
b18da3cad9 Move IPlatformCompat.aidl definition to framework.jar
There are non-app process usecases in framework code that need to have
access to this API.
Created a new package android.compat in frameworks/base/core following
previous definition of android.compat.Compatibility for app processes
(http://cs/android/libcore/luni/src/main/java/android/compat/Compatibility.java).

Bug: 137769727
Test: m
Change-Id: Ifc1b97ad40c2baf65a86169e101acfa72e3aae5f
Merged-In: Ifc1b97ad40c2baf65a86169e101acfa72e3aae5f
2019-08-14 16:35:14 +01:00
atrost
4f8c307dbf resolve merge conflicts of 56509ddb842b8770249de6d4d80a2fc7dc9c87e1 to stage-aosp-master
Bug: 138222871
Test: I solemnly swear I tested this conflict resolution.
Change-Id: Ia3965d41d6756a25dd44a0ed676de5ec8b5bae21
Merged-In: Id523d31e7b6d2def9371753ae34cba883cd62a54
2019-07-29 15:21:58 +01:00
atrost
7e6060f448 Read compat config in CompatConfig class.
Use the auto generated parser, and test by feeding streams of XML.

Test: atest FrameworksServicesTests
Bug: 138222871
Change-Id: Id523d31e7b6d2def9371753ae34cba883cd62a54
Merged-In: Id523d31e7b6d2def9371753ae34cba883cd62a54
2019-07-26 15:43:09 +00:00
Andrei Onea
4fd8dabd52 resolve merge conflicts of 130e0ade7b3ed33038518c9eb8329cbee066ef2a to stage-aosp-master
Bug: None
Test: I solemnly swear I tested this conflict resolution.
Change-Id: Ie8cfba397930a1bd5ec947f4834478bb629fa640
Merged-In: I19e5fbfefcf59e0b53b197ea8e9e3cb78439b4c4
2019-07-25 18:17:30 +00:00
Andrei Onea
6cd9d4d18e Make PlatformCompat a Binder class
This allows PlatformCompat to be called from anywhere in the platform.
In follow-up CLs, we'll define permissions for each method and/or
filtering rules to prevent abuse from apps.

Test: m
Bug: 137769727
Change-Id: I19e5fbfefcf59e0b53b197ea8e9e3cb78439b4c4
Merged-In: I19e5fbfefcf59e0b53b197ea8e9e3cb78439b4c4
2019-07-25 12:38:04 +00:00
Lorenzo Colitti
433f7c4178 Merge "Properly use versioned interfaces." am: 9572afce76
am: b92fbe0435

Change-Id: Idf49e840263ef32b9ee4fafa6718d4f893ea7c87
2019-05-22 01:20:45 -07:00
Lorenzo Colitti
fe0c38aed5 Properly use versioned interfaces.
Our stable AIDL interfaces need to use versioned build targets,
otherwise getVersion will always return 0, which makes it
impossible to support different components at different versions.

List generated with:
find . -name Android.bp -exec egrep \
    -H "(netd|dnsresolver|ipmemorystore|networkstack).aidl.interface(s?)-(java|cpp)" {} \;

Bug: 133124190
Test: m
Change-Id: Id175c99daa77507847673777a8dcce51897ab17b
2019-05-22 03:12:59 +00:00
Luke Huang
6764eff395 Merge "Use IDnsResolver instead of INetd for resolver related binder commands" am: b9ef4dd299 am: 1711278ce2
am: ceb74821a3

Change-Id: I2d642b71df25934fddd8a1476b5d27457628b8e2
2019-03-29 02:24:24 -07:00
Luke Huang
b9ef4dd299 Merge "Use IDnsResolver instead of INetd for resolver related binder commands" 2019-03-29 08:45:19 +00:00
Luke Huang
6591477a5b Use IDnsResolver instead of INetd for resolver related binder commands
migrate resolver related commands from INetd to IDnsResolver

Bug: 126141549
Test: atest FrameworksNetTests ConnectivityServiceTest Nat464XlatTest
      atest DnsManagerTest
Change-Id: I559c0c1304d53dde408c062e1a52e742595e7cbe
2019-03-27 17:39:07 +08:00
Siarhei Vishniakou
4dfa47054e Move tag definitions into policy
Currently, the tags are defined in system/core.
Instead, reserve a range in system/core and define the tags in policy.

Next, we add a flag for interceptKeyBeforeQueueing.

Bug: 128933363
Test: adb logcat -b events, turn on screen, then press power button and
observe the logs.

Change-Id: I1fde2a2e7451ec67987ad3b09abc28be64410427
2019-03-26 12:56:08 -07:00
Siarhei Vishniakou
6f87741272 Move tag definitions into policy
Currently, the tags are defined in system/core.
Instead, reserve a range in system/core and define the tags in policy.

Next, we add a flag for interceptKeyBeforeQueueing.

Bug: 128933363
Test: adb logcat -b events, turn on screen, then press power button and
observe the logs.

Change-Id: I1fde2a2e7451ec67987ad3b09abc28be64410427
Merged-In: I1fde2a2e7451ec67987ad3b09abc28be64410427
2019-03-26 12:46:58 -07:00
Marco Nelissen
ec7ed1c990 Remove support for updatable media components in apk
Bug: 123250010
Test: boot, play video
Change-Id: I95f8d28cdb4ce0bef04711ba0e9322fe8bfd79d9
2019-02-04 16:02:35 +00:00
Peter Kalauskas
9590e009e9 Merge "Update android.hidl.manager-V1.0-java to V1.2" am: b9e216c2b6 am: e20b0fb677
am: d9c2837cad

Change-Id: Icf8910e23129481daa2ad9f5b42f0828ebe5b6d3
2019-01-31 14:39:43 -08:00
Peter Kalauskas
b9e216c2b6 Merge "Update android.hidl.manager-V1.0-java to V1.2" 2019-01-31 22:05:47 +00:00
Peter Kalauskas
65589e9563 Update android.hidl.manager-V1.0-java to V1.2
Test: Manual
Bug: 123307146
Change-Id: I8dcd291c187af2cb20fd9a8f09bd55e75a2762e1
2019-01-31 21:40:12 +00:00
Howard Chen
f17f42b0df Add the DynamicAndroid Service
Define the DynamicAndroid with AIDL.
  Add a java implementation.
  Start a service instance in the system server.
  Add a permission test.

Bug: 122015653
Test: Build & Test on a pixel phone with following command \
  ./frameworks/base/services/tests/runtests.py -e class com.android.server.DynamicAndroidTest

Merged-In: I2e54b6b71fac4a4c5a9c9c25ce6bdac74cddcfb7
Change-Id: I2e54b6b71fac4a4c5a9c9c25ce6bdac74cddcfb7
2019-01-31 15:10:21 +08:00
Howard Chen
0a94764738 Add the DynamicAndroid Service
Define the DynamicAndroid with AIDL.
  Add a java implementation.
  Start a service instance in the system server.
  Add a permission test.

Bug: 122015653
Test: Build & Test on a pixel phone with following command \
  ./frameworks/base/services/tests/runtests.py -e class com.android.server.DynamicAndroidTest

Change-Id: I2e54b6b71fac4a4c5a9c9c25ce6bdac74cddcfb7
2019-01-31 14:19:34 +08:00
Lorenzo Colitti
9dfc3c1b45 Merge changes from topic "netd-event-listener-aidl" am: 481251a0c2 am: 379029671a
am: 94cffb3a6c

Change-Id: I2b30cac46eb96e3a0425088f516176ce5ac4fd28
2018-12-11 23:13:42 -08:00
Lorenzo Colitti
31324cb4b2 Depend on the stable AIDL version of the netd metrics interface.
We used to include the AIDL file directly, but that does not
provide useful features such as getVersion() support and is
generally not the preferred approach.

Test: builds, boots
Test: atest FrameworksNetTests android.net.cts.ConnectivityManagerTest
Change-Id: I7ca56e4b440dc2321f5a7b77bac630a48e69100a
2018-12-12 01:03:55 +09:00
Luke Huang
e405415a62 Merge "Migrate INetd to stable aidl" am: 9677dde14a am: ef6b675a8c
am: c2126e2008

Change-Id: I9866b431cd5ddeb318e164fc2a897537a3a7a88d
2018-12-10 03:00:58 -08:00
Luke Huang
734c4cea3c Migrate INetd to stable aidl
Del the linking of old lib file and add new one.

Test: runtest frameworks-net passes
Change-Id: I7258f7c51718ff5f07e7bfe301b6c5f242b9da5a
2018-12-07 10:40:45 +00:00
Luke Huang
2ef88d1875 Move netd related file group to the end for avoiding conflict
This patch should change no functionality.

Test: builded pass
Change-Id: I8161a9a365c6bfcd92f4b7a8fd641ad3a483d09c
Merged-In: If3e387ae9fcc22da7a4feca30c20391e5b236728
2018-12-07 05:33:18 +00:00
Luke Huang
11937a9238 Move netd related file group to the end for avoiding conflict
This patch should change no functionality.

Test: builded pass
Change-Id: If3e387ae9fcc22da7a4feca30c20391e5b236728
2018-12-07 11:51:40 +08:00
Anton Hansson
b27f0fa222 Add gps_debug.conf module
Copy the gps_debug.conf from the device-specific folders to
a place closer to the code that uses it.

Bug: 112879252
Bug: 120066492
Test: make
Change-Id: I937e699cb9e891c511ca7b9f4740d45e19668c54
Merged-In: I937e699cb9e891c511ca7b9f4740d45e19668c54
Exempt-From-Owner-Approval: cp from internal
(cherry picked from commit 11905c6b2c8d2c7b3001cd913619d8b17c533ac1)
2018-11-29 09:48:44 +00:00
Anton Hansson
11905c6b2c Add gps_debug.conf module
Copy the gps_debug.conf from the device-specific folders to
a place closer to the code that uses it.

Bug: 112879252
Bug: 120066492
Test: make
Change-Id: I937e699cb9e891c511ca7b9f4740d45e19668c54
2018-11-27 21:36:03 +00:00
Mårten Kongstad
06a1ac8229 Prepare for switch to idmap2
Prepare the idmap and asset managers for interfacing with idmap2 instead
of today's installd + idmap pipeline, but don't make the switch just
yet.

Instead, idmap2 runs as its own native daemon with an AIDL interface.
This removes the need for installd to fork and exec on each idmap call,
saving about 50 ms per call.

Bug: 78815803
Test: atest OverlayDeviceTests OverlayHostTests
Change-Id: I60852e15d99329896ff9de6559d1e7cd1c67e33d
2018-11-12 13:24:33 -08:00
Wale Ogunwale
db485dec8b Don't use WMS.mWindowMap to synchronize WM critical section (36/n)
Use new field WMS.mGlobalLock instead. This will make it easier to
switch the lock to the same object used by ActivityTaskManagerService
in an upcoming CL.

Test: Existing tests pass
Bug: 80414790
Change-Id: I4202e9028395d79cc60b01ed795528b469a16bf1
2018-11-04 01:26:51 +00:00
Nandana Dutt
d1773d6459 Merge "Add DumpstateOptions java implementation" am: 52502ef1a1 am: 8a9f23c8a1
am: 1d1184cf83

Change-Id: I556407ee455b92e3bae34dfa603e159b99f45080
2018-10-12 11:21:26 -07:00
Nandana Dutt
b3f7168136 Add DumpstateOptions java implementation
DumpstateOptions will be used to pass options to Dumpstate service
for specifying arguments for taking bugreports.

Test: m
Test: adb bugreport

Change-Id: I4dc9511f0be2f86239ea9094a3c527b6ce0d1d41
2018-10-11 17:05:35 +01:00
Luke Huang
f33cfcf50d Merge "Refactor tetherGetStats by using stable aidl structure" am: 335253df0f am: f81dce0f79
am: 7ec816b07c

Change-Id: Id3d6e57c10afb06271228b59a40cec91edaed7e4
2018-10-11 00:38:42 -07:00
Luke Huang
13b79e83aa Refactor tetherGetStats by using stable aidl structure
Use stable aidl structure instead of persistbundle

Test: runtest frameworks-net passes
Test: manual testing of tetherGetStats function works

Change-Id: I6835541d450446ba7993ac9f5b783d34229b79cb
2018-10-04 16:24:44 +08:00
Steven Moreland
9fb99abd78 Merge "services.core.unboosted: hidl manager->static_libs" into stage-aosp-master am: 3c6186c474
am: 39f3c39e74

Change-Id: I7821306a1a8f09511459a716305fbe1da1d83d91
2018-06-26 14:29:25 -07:00
Steven Moreland
1f58a288e7 services.core.unboosted: hidl manager->static_libs
Bug: 77307025
Test: boot device w/o hidl libs on boot classpath, no loading
  error

Change-Id: Iae2b0015a29de71c22e6bc31004613bbf4ca971b
2018-06-26 16:07:22 +00:00
Kevin Chyn
55a5b59a9b 3/n: Add face HIDL to build
Test: builds

Bug: 110385761
Change-Id: Id2345eb934158cdf2d1dc8ee32ba9e9a595a54a1
2018-06-19 19:27:05 -07:00