4728 Commits

Author SHA1 Message Date
Bart Sears
4a26c391d0 Merge "CEC: Explicitly turn on screen for remote control passthrough" into lmp-mr1-dev 2015-03-27 20:48:38 +00:00
Christopher Tate
dbe0dd160e When scanning unbundled apps, only install the expected APK tree
We now make sure, when scanning post-factory app installs, that we do not
accidentally activate a "leaked" or otherwise superfluous APK tree that the
scan algorithm happens to encounter before the one that we expect a priori
based on the persisted package-installation state.  When we find such an
extraneous installation we ignore it in favor of the expected one, similarly
to the policy used when collecting system-bundled packages that have been
updated.

Even if we find an unexpected APK for the package, if the expected one
turns out to be absent we fall back to the existing "we thought this app
was present and now it isn't" logic.

Bug 19602471

Change-Id: I141a93661946176c05d8cf52a123bdf75c8eef74
2015-03-26 15:55:30 -07:00
Jinsuk Kim
bd3deee37b CEC: Explicitly turn on screen for remote control passthrough
Ensures that the playback device turns on display output signal
upon receiving CEC command <User Control Pressed>.

Bug: 19518981
Change-Id: I4f898380c9ffc071da2357a51e61309ae5d233f5
(cherry picked from commit 9b8507c52ae845c8eed9fd9952bf66538934b8fd)
2015-03-26 02:01:11 +00:00
Jeff Brown
38d3feb76c Disable more hotkeys while in setup.
Disables fallback key processing for CALL, CAMERA, and HEADSETHOOK
buttons.

Bug: 19767816
Change-Id: I423103c367e05827c939cd8d8dbecb6012b0e9f0
2015-03-20 13:26:09 -07:00
Andres Morales
c8f952ce9f Write correct checksum when formatting partition
OEM unlock enabled bit is not computed in the checksum,
causing OEM Unlocking to be disabled after the second
reboot.

Bug: 19829441
Change-Id: I100bf5d3958b89323ee35b9e97b19c162209fcd7
2015-03-19 17:18:01 +00:00
Junda Liu
985f52cde5 Fix incorrect condition for sub id check.
Bug: b/19277299
Change-Id: Iea6806926f0e9d9404a3f2613d03b8a0607fea54
2015-02-23 16:06:51 -08:00
Craig Mautner
ca0653a424 Do not make ActivityContainer available to apps. DO NOT MERGE
A security leak was discovered whereby a malicious app could get the
IActivityContainer object from one app and use it to inject events
into another app. This fix removes the availability of the
IActivityContainer and replaces its one use with a method for
returning the information the IActivityContainer was used for.

Fixes bug 19394591.

Change-Id: Ib3cec25b25130cd8e098892c057742cfd575cfdd
2015-02-17 20:41:39 +00:00
John Spurlock
f45e5dbf59 Merge "NoMan: Initialize filter value reported to listeners." into lmp-mr1-dev 2015-02-12 22:52:13 +00:00
John Spurlock
f370177e94 NoMan: Initialize filter value reported to listeners.
In addition to relying on change callbacks.

Bug: 19288429
Change-Id: Id54473e5fbb4eac3778781a2052ba0103076f8d1
2015-02-12 13:29:37 -05:00
Lorenzo Colitti
c7ccc393b4 Merge "Make reportInetCondition revalidate if the report differs from our state" into lmp-mr1-dev 2015-02-12 02:30:56 +00:00
Michael Wright
3292c0e264 Merge "Stop active media projections on user switch." into lmp-mr1-dev 2015-02-11 18:23:55 +00:00
Jeff Davidson
50996a12a8 Merge "Do not enforce CONTROL_VPN for calls from lockdown VPN." into lmp-mr1-dev 2015-02-11 08:25:27 +00:00
Jeff Davidson
b21298a686 Do not enforce CONTROL_VPN for calls from lockdown VPN.
Clearly document which methods in Vpn.java are designed to be used to
service a Binder call, and which must therefore check permissions and
clear the calling identity, and which methods are designed for
internal use only and which therefore need not check permission.

Add a new startLegacyVpnPrivileged method which bypasses the
permission checks, to be used by lockdown VPN which is a trusted
system service. Ensure that the existing startLegacyVpn method checks
permissions as this is used whenever we respond to a binder call.

Bug: 19311172
Change-Id: I34f13258ee7481f1356bc523124cf5db068b4972
2015-02-10 23:41:42 -08:00
Lorenzo Colitti
c38b90bb6b Merge "Make getNetworkInfo() take into account VPN underlying networks." into lmp-mr1-dev 2015-02-11 07:18:17 +00:00
Shishir Agrawal
64ce5f8fab GpsLocationProvider: Read data enabled status from TelephonyManager.
Bug: 18814559
Change-Id: I0333050d2a5b8d484466e1b1914dcfb9965398c9
2015-02-10 19:20:16 -08:00
Lorenzo Colitti
0831f66f19 Make reportInetCondition revalidate if the report differs from our state
1. If reportInetCondition says the network is not working, and
   the network is already marked not validated, don't revalidate
   it. This was superfluous and should save battery.
2. If reportInetCondition says the network is working, and the
   network is not marked as validated, revalidated. This will
   allow us to get out of a validated state quickly based on app
   input (e.g., allowing GCM's exponential backoff timer to drive
   revalidation instead of our 10-minute timer).

Bug: 19258761
Bug: 19209043
Change-Id: Iaa4bac82d117ed1f4088dab106e6f6ce46b34bc3
2015-02-11 11:03:50 +09:00
Lorenzo Colitti
d6a7980dd9 Make getNetworkInfo() take into account VPN underlying networks.
If a user is subject to a VPN, getActiveNetworkInfo() will return
the VPN's underlying network (e.g., TYPE_WIFI), so that apps that
call getActiveNetworkInfo to answer questions like "is the device
connected to wifi?" will continue to work. Make getNetworkInfo
do this as well: if the query is for a network type that is
underlying the current user's VPN, then return that network.

Bug: 19196545
Change-Id: Ic5a651735b927c758594a26d26a03fbd704b52e6
2015-02-11 10:21:01 +09:00
Rubin Xu
99abeed2bb Perform post installation operations directly if backup manager is disabled
bug: 19312753

Change-Id: I4acdd1e3af6a6be0c51affc42de167993c736b2f
2015-02-09 15:36:30 +00:00
Michael Wright
05aab5810a Stop active media projections on user switch.
Bug: 19278080
Change-Id: I63cc8aa12954d4de257b793967d3845a6f86dc3f
2015-02-06 14:08:13 -08:00
Christopher Tate
c83d3e4b72 Always re-establish kernel alarms when considering new alarm set
As a backstop against missed alarm delivery / wakeups or clock slew,
make sure to always schedule a kernel alarm for the next alarm events
of interest when we've reexamined the set of deliverable alarms.

Bug 19201933

Change-Id: I3cd37a63dfb0c8258941497d4ba516ed00e2edad
2015-02-04 13:48:29 -08:00
Paul Jensen
8fe1742946 Facilitate network validation on networks with a per-network PAC.
On networks with a per-network PAC, Network.openConnection(URL) will
fetch using NO_PROXY.  This will fail on networks where Internet
access is only permitted via the proxy.  Always failing network
validation has the potential to disable WiFi auto-join.  Instead
of performing the normal connectivity check, instead attempt to
fetch the PAC, as this is meant to succeed with NO_PROXY.

bug:19143573
Change-Id: Ia482f5c046d338c27daf42571f20851dfa36671c
2015-02-03 11:28:55 -05:00
Jinsuk Kim
3457ae4709 Merge "Revert "CEC: Let playback device switch TV input after bootup"" into lmp-mr1-dev 2015-01-30 22:00:40 +00:00
Jinsuk Kim
4361549891 Revert "CEC: Let playback device switch TV input after bootup"
This reverts commit 8913a0e1e8559d96e82b1ff408dd312ed279021b.

Change-Id: Ibfabdd94206141274a69040e0ed90ba29aeae75b
2015-01-30 21:58:18 +00:00
Jinsuk Kim
9c5ccc3684 Merge "CEC: Discard key event to itself" into lmp-mr1-dev 2015-01-29 22:33:43 +00:00
Jinsuk Kim
454fab5219 CEC: Discard key event to itself
Should discard keyevents if the target address is the device itself.

Bug: 19188660
Change-Id: Id47d79c996f60c9d90540f28c4b2509976d2f378
2015-01-30 07:28:10 +09:00
Jinsuk Kim
3f92347424 Merge "CEC: Add CEC device upon receiving <Report Physical Address>" into lmp-mr1-dev 2015-01-29 22:21:54 +00:00
Jinsuk Kim
07600116b5 CEC: Ensure stable AVR connection
Make sure AVR device removal due to hotplug detection failure occur
in a less strict manner - doing it only if the failure is detected
3 times in a row.

Bug: 19171321
Change-Id: I1479663b05cdc957cc52123799c756f6b74f6708
2015-01-29 06:47:34 +00:00
Jinsuk Kim
2ee0d6f44d CEC: Stop ARC if hotplug event is asserted low
Updated to stop ARC as specified in HEAC 2.4 transmission condition.

Bug: 19170947
Change-Id: Ibf797ce3b49f32561ef0c36b6874e7ebe19ed65a
2015-01-29 06:45:02 +00:00
Jinsuk Kim
7640d9895c CEC: Fix a regression bug
The HdmiControlService.getActiveSource() has a regression (exception)
when calling getDeviceInfoByPath since method should be called on
a service thread. Introduced a method that can be invoked safely
from the main thread.

Bug: 19170884
Change-Id: I393161e08c916270faf46147a97076bc573b808f
2015-01-29 06:41:49 +00:00
Jinsuk Kim
7cd4a589af CEC: Add CEC device upon receiving <Report Physical Address>
Help devices be processed sooner when new device detection operation
takes longer than usual.

Bug: 19181472
Change-Id: I96c29081a9c7c9f73ebcd027ed9d18056dc89bf9
2015-01-29 11:20:53 +09:00
Jinsuk Kim
c9914a22d8 CEC: Let <Active Source> from the active source work
<Active Source> from the device which is already in active
source state is being ignored now, but it should work with an effect
of putting input view foreground in case it is hidden behind
home launcher overlay.

For better user experience, this change lets the command from
the active source takes effect to hide the overlay if present.

Bug: 19171319
Change-Id: I43d2646f2ad470b3636e82ff71ac83cf0031ef6c
2015-01-28 16:37:17 +09:00
Christopher Tate
f37b20e1aa Merge "Fix 'always' preferred app assignment" into lmp-mr1-dev 2015-01-28 01:14:12 +00:00
Christopher Tate
57792912ee Fix 'always' preferred app assignment
In the case when some possible resolutions of a given intent are at
different priorities (typically when they're intended as fallbacks when
no "normal" handler for the intent exists) the check for "is this the
same set of possible handlers that we saw last time?" was broken.  We
now ignore resolver priority entirely in that check: match set comparison
should be orthogonal to prioritization within the set, and indeed the
priority is dealt with separately in any event.

Bug 19011225

Change-Id: I3c1658442cc88b1f4a5c5f2fe9f64472799e156c
2015-01-27 13:52:17 -08:00
Tim Kilbourn
9626854543 Add a config for whether to start in touch mode.
Bug: 18925810
Change-Id: Ic9b956cde380cffcad7ca229f1669692b1743e6d
2015-01-27 13:51:58 -08:00
Craig Mautner
5426e7ae93 Merge "Defer tap outside stack until multiwindows" into lmp-mr1-dev 2015-01-27 20:48:55 +00:00
Craig Mautner
baf6bef001 Defer tap outside stack until multiwindows
Taps outside of the stack boundary were causing the current app to
lose focus. This led to timeouts waiting for the app to respond.

Disabling the tap recognition keeps the focus from changing. It will
be reenabled for multiwindows.

Fixes bug 17721767.

Change-Id: Iad854b19979390e73b97239e489ad7ef82e03d47
2015-01-27 11:44:59 -08:00
Lorenzo Colitti
525588c593 Merge "Make NetworkMonitor less aggressive on broken networks." into lmp-mr1-dev 2015-01-27 11:41:10 +00:00
Craig Mautner
49880eeb00 Merge "Stop logging service starts and stops." into lmp-mr1-dev 2015-01-27 01:15:35 +00:00
Wonsik Kim
485e7e13f4 TIF: fix loud volume after input switch when volume is 0
Bug: 19134440
Change-Id: I6291f299a27315e79b505ea36bf96c79437e6b53
2015-01-27 01:06:37 +00:00
Craig Mautner
9851d03819 Stop logging service starts and stops.
Completes work on bug 18201239.

Change-Id: I80686351ac91e48bf113976a000b351b423d8dd2
2015-01-26 14:33:39 -08:00
Lorenzo Colitti
09dff843b8 Merge "Only try to fetch time from NTP if there is a network connection." into lmp-mr1-dev 2015-01-26 22:08:19 +00:00
Craig Mautner
8995e140ad Merge "Add reason string for bringing stack to front" into lmp-mr1-dev 2015-01-26 20:05:45 +00:00
Craig Mautner
299f960e5e Add reason string for bringing stack to front
Additional debug and useful information.
Also removed am_resume_activity verbosity and refactored method to
eliminate unused parameter.

For bug 17721767.

Change-Id: Ie1c0652a38a0c6ae6db27a52a9e5da29e252e300
2015-01-26 10:57:11 -08:00
Lorenzo Colitti
351bfad339 Make NetworkMonitor less aggressive on broken networks.
1. Retry validation 3 times instead of 10.

Reducing the number of retries speeds up dead network detection
and saves battery on networks that are don't have Internet access
(or block our connectivity checks).

Retrying 10 times is overkill. Each attempt sends 5-10 DNS
requests, waits 10 seconds to transfer only 3 or 4 packets, and
can last up to tens of seconds. Also, in MR1 we now retry every
10 minutes.

2. Make periodic revalidation only try once.

When validating periodically to see if a non-working connection
is working again, only make one attempt every 10 minutes, not
three.

3. Rename "retries" to "attempts" to make things a bit clearer.

Bug: 18922569
Bug: 18869302
Change-Id: I5f70b420c4f1bac0c33bb9ab6afb322902cdac4b
2015-01-26 17:30:22 +09:00
Lorenzo Colitti
df59053588 Only try to fetch time from NTP if there is a network connection.
Bug: 19046107
Change-Id: Iff647ee33fe0eb9b530d7baad636d32b386e4fa7
2015-01-26 15:24:07 +09:00
Jinsuk Kim
56c119abde Merge "CEC: Handles initiation of press-and-hold correctly" into lmp-mr1-dev 2015-01-23 21:10:38 +00:00
Jinsuk Kim
c4228a7281 CEC: Handles initiation of press-and-hold correctly
Previously the time gap between the first and the second key event
for repeated keys(press-and-hold) can be bigger than the threshold,
which violates CEC spec. This CL rectifies it by managing its own
state rather than relying on Android key handler.

Bug: 19117830

Change-Id: Iedfa48f9ab826252e8616d1c3b7491e8b8333c81
2015-01-23 18:20:20 +09:00
Jinsuk Kim
76cf035513 Merge "CEC: Add logic to return to internal source" into lmp-mr1-dev 2015-01-23 06:51:58 +00:00
Craig Mautner
dbabf37fd3 Merge "Even more debug for bug 17721767." into lmp-mr1-dev 2015-01-22 23:17:47 +00:00
Craig Mautner
de313753d0 Even more debug for bug 17721767.
This time adding events for stack movement and focus change.

Change-Id: Icdff9763ac2daf85c615992fa2c8e418e907908c
2015-01-22 14:28:03 -08:00