efdb8454275954e54bd11a59d450cbac30c13da4 |
|
21-Apr-2016 |
Rebecca Silberstein <silberst@google.com> |
NativeDaemonConnector: add waitForCallbacks method Add a method that allows callers to wait until all unsolicited responses received from the native daemon during a command are processed. When commands are issued to a native daemon (such as netd) through the NativeDaemonConnector we block until the command response is received. Any responses or events that are a side-effect (considered "unsolicited") of the command are placed in a Message and handled as callbacks. The order of their processing is not guaranteed and, as we have seen from bugreports, can be handled several seconds later - causing the SoftAP that was just set up to be torn down because a late interface down/removed is indistinguishable from a new interface down/removed. This CL adds a method that first checks to make sure callback thread is not the same thread as used for the blocking call. The new waitForCallbacks method uses a CountDownLatch to force the calling thread to wait until all unsolicited responses received from the native daemon during the execution of the command are handled. The wifiFirmwareReload method is also updated to use the new waitForCallbacks method. BUG: 27857665 Change-Id: I3e22978f720b1cbf57fbb64ad4fea73f8c2d408a
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
ae107afe8e95b42543c05f67759a4ee32cfc6fb7 |
|
11-Apr-2016 |
Lorenzo Colitti <lorenzo@google.com> |
If we want to release the lock, release instead of acquiring it. The intent of this code seems pretty clearly to release the lock, not acquire it. This is bad since it's a refcounted wakelock. Change-Id: I0f7590ab697133bd82db8a1a515453316c6a80dc
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
cd63d247f08eddd506a679ffa244d6ac6c4742b1 |
|
10-Apr-2016 |
Lorenzo Colitti <lorenzo@google.com> |
Improve Tethering and NativeDaemonConnector logging. 1. Deduplicate the Tethering message numbers, and use MessageUtils to convert them to strings. 2. Add a warning to NativeDaemonConnector when an unsolicited event is more than 500ms late or takes more than 500ms to process. Bug: 27857665 Change-Id: I379aef9257027d1ccf30906e79c6389ef1f95420
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
dda655210fea87f0e4d64333891a376c2de3f8a6 |
|
19-Nov-2015 |
Daichi Hirono <hirono@google.com> |
Add capability to receive FD with NativeDaemonConnector. BUG=25755372 Change-Id: I2888219b77cf04f4bf749d5518ff62ba16258f2d
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
8948c01eb726ec79983472e5597ddac8004f9f44 |
|
03-Nov-2015 |
Jeff Sharkey <jsharkey@android.com> |
Yell when calling installd with PM lock held. As a matter of policy, we should never be holding the mPackages lock while calling down into installd. This little bit of logic helps us catch accidental cases where this happens. Change-Id: I676c81df43ef936ffd36290d45a79429630c1b4b
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
e41dc59657f6345e35587504cff6cf44f6fcaa6e |
|
03-Nov-2015 |
Jeff Sharkey <jsharkey@android.com> |
Yell if NDC callers are holding bad locks. The current MountService design heavily depends on down-callers not holding any locks, since the vast majority of events are unsolicited and bubble up to the framework. This simple API gives us an easy way to track down people calling while holding a lock they shouldn't be. Bug: 25443096 Change-Id: Ifcbda95f00d5be8c1b88d58ca67927e76c713c3e
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
14cbe52150bad38ab7c14c868e25a68d354f8282 |
|
08-Jul-2015 |
Jeff Sharkey <jsharkey@android.com> |
Kill MediaProvider during drastic changes. Sadly MediaProvider makes a ton of assumptions about storage paths not changing. To ensure that it picks up radical storage changes, kill it and let it restart to pick up new paths. Also give ourselves a longer timeout when benchmarking. Bug: 20275423 Change-Id: I9971c4667dabdc685cb23528443f085f152c461d
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
8101ee6884e9fe954aeaf3c08afd01ab1714f306 |
|
23-Jun-2015 |
Todd Kennedy <toddke@google.com> |
Handle volume benchmark timeout If a volume benchmark operation times out, we don't want to show a cryptic toast message. Instead, we return a very large integer [eg Long.MAX_INT]. The storage wizard can then use this value to show an appropriate dialog if it chooses. Bug: 21376364 Change-Id: I3d97336e19c93511cfff2cbdb2f07ab033a1143d
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
4887789e44cdb16b042a35e8ec03983213e88ac6 |
|
18-Mar-2015 |
Jeff Sharkey <jsharkey@android.com> |
Progress towards dynamic storage support. Storage devices are no longer hard-coded, and instead bubble up from whatever Disk and VolumeBase that vold uncovered, turning into sibling Java objects in MountService. We now treat vold events as the source-of-truth for state, and synchronize our state by asking vold to "reset" whenever we reconnect. We've now moved to a model where all storage devices are mounted in the root mount namespace (user boundaries protected with GIDs), so we no longer need app-to-vold path translation. This also means that zygote only needs to bind mount the user-specific /mnt/user/n/ path onto /storage/self/ to make legacy paths like /sdcard work. This grealy simplifies a lot of system code. Many parts of the platform depend on a primary storage device always being present, so we hack together a stub StorageVolume when vold doesn't have a volume ready yet. StorageVolume isn't really a volume anymore; it's the user-specific view onto a volume, so MountService now filters and builds them based on the calling user. StorageVolume is now immutable, making it easier to reason about. Environment now builds all of its paths dynamically based on active volumes. Adds utility methods to turn int types and flags into user-readable strings for debugging purposes. Remove UMS sharing support for now, since no current devices support it; MTP is the recommended solution going forward because it offers better multi-user support. Simplify unmount logic, since vold will now gladly trigger EJECTING broadcast and kill stubborn processes. Bug: 19993667 Change-Id: I9842280e61974c91bae15d764e386969aedcd338
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
c38182ff3b1ecaf5e7a7270074bbab7f37819d3d |
|
11-Nov-2014 |
Paul Lawrence <paullawrence@google.com> |
Add mechanism for securely returning parameters though NativeDaemonConnector If the first word in the response is {{sensitive}}, don't log the body of the response. Bug: 18260068 Change-Id: Ibfb5c6abab1d04b4321cdbcf6c7cf6f18f903146
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
d66f3e584ba9e5c9b104b111305edceedd23fcb0 |
|
11-Nov-2014 |
Paul Lawrence <paullawrence@google.com> |
Revert "DO NOT MERGE: Don't log passwords returned from vdc" This reverts commit 70c9a06af0028cb0d0d8d36af7ff040a1a4e331c. The original change disabled all logging of RCVed messages in NativeDaemonConnector. For MR1 we want a much more surgical disabling of sensitive messages. First, though, we have to defeat the automerger. Change-Id: I712919aee2db63f7fc0b2c6d6a2a658325dce596
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
70c9a06af0028cb0d0d8d36af7ff040a1a4e331c |
|
05-Nov-2014 |
Paul Lawrence <paullawrence@google.com> |
DO NOT MERGE: Don't log passwords returned from vdc Turns off logging of responses from native daemon connector altogether. Proper solution to follow in LMP MR1 Bug: 18260068 Change-Id: I25bc9cb61049a3efdd9a9cd11195864a04ef05fd
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
7f44ff8d6b4d115420e7bd5f08f12825738afd54 |
|
08-May-2014 |
Robert Greenwalt <rgreenwalt@google.com> |
Turn down the logging. Cut per-msg logging by 1/3 in NDC so we see that much more. Change-Id: I406297d98f2649a88b16c7be3cf90757d009c762
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
2ffa11e4b71c545e34533ef827bdc1a07fbe8246 |
|
22-Apr-2014 |
Dianne Hackborn <hackbod@google.com> |
Start collecting mobile radio activity from the radio. Hook in to the new radio API to find out when the radio is active and use that to track its state in batter stats. We also still have the data being tracked from the kernel's emulation, and continue to use that if we don't get data from the radio. Currently this monitoring is turned off until some issues in the radio can be fixed that are providing bad data. Also add a new API to get estimated drain and charge times. Change-Id: Ifc4900fabb8f848f9cda361dce698664ea75f175
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
4590e52f3d0558e01322fe4dd55bb612afdfb079 |
|
24-Mar-2014 |
Dianne Hackborn <hackbod@google.com> |
Battery stats: wake locks, radio active, cleanup. - Improve wake lock work source updates to also update the current history tag, in case the new work source gets recorded in the history. - Fix bug in recording radio active time that was not distributing any time to apps. - No longer hold a wake lock while dispatching data conn active call, since it comes with its own timestamp. - Fix issue where the top app was not being cleared while the screen was off. - Remove obsolete STATS_LAST stats type. - Fix bug that was not clearing the total run time when resetting the stats. Change-Id: Iabe17a9edf34f762374ae09fcffb8a819cf72e30
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
77b987f1a1bb6028a871de01065b94c4cfff0b5c |
|
27-Feb-2014 |
Dianne Hackborn <hackbod@google.com> |
Hold a wake lock while dispatching network activity events. Also add new API for determining whether the current data network is active, and thus better scheduling network operations. This API is designed to not be tied to a mobile network -- regardless of the network, apps can use it to determine whether they should initiate activity or wait. On non-mobile networks, it simply always reports as the network being active. This changed involved reworking how the idle timers are done so that we only register an idle timer with the current default network. This way, we can know whether we currently expect to get callbacks about the network being active, or should just always report that it is active. (Ultimately we need to be getting this radio active data from the radio itself.) Change-Id: Iaf6cc91a960d7542a70b72f87a7db26d12c4ea8e
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|
9158825f9c41869689d6b1786d7c7aa8bdd524ce |
|
22-Nov-2013 |
Amith Yamasani <yamasani@google.com> |
Move some system services to separate directories Refactored the directory structure so that services can be optionally excluded. This is step 1. Will be followed by another change that makes it possible to remove services from the build. Change-Id: Ideacedfd34b5e213217ad3ff4ebb21c4a8e73f85
/frameworks/base/services/core/java/com/android/server/NativeDaemonConnector.java
|