Merge commit '07ca8c71f47ac8c61b3aef0210e44d2c48e62e48'
* commit '07ca8c71f47ac8c61b3aef0210e44d2c48e62e48':
Fix many of the ANRs introduced by scheduling classes.
Merge commit 'aa088447baadd2e0bbcfd18cc529645610c13ddc'
* commit 'aa088447baadd2e0bbcfd18cc529645610c13ddc':
Hold the current transport instantiated all the time.
Create a new public IntentSender class that can be used by PackageManager instead.
This new class uses IIntentSender internally and can only be created by PendingIntent for now.
Provide a new getIntentSender api in PendingIntent to create an instance of this class.
Move IIntentSender and IIntentReceiver from android.app to android.content
Change imports of IIntentSender and IIntentReceiver to reflect the new package name
The PackageManager api has been named as freeStorageWithIntent and will be renamed as freeStorage
once the older api(which has been deprecated) will be removed shortly.
Merge commit '63d2700036d0f73cbde27f0fa724d30045b4bb07'
* commit '63d2700036d0f73cbde27f0fa724d30045b4bb07':
Allow privileged callers to schedule a backup pass for any app.
We weren't bumping the oom_adj of processes receiving a registered broadcast. Previously
this wasn't a problem, because those processes are allowed to have their oom_adj
managed by whatever else is in them and if the registered receiver goes away no problem.
But now this is also controlling the scheduling class, so we need to bump them up.
This is probably good anyway, since the developer has the same assurance of their process
not being killing in the middle of registered receivers like it had always been for
manifest receivers.
Also fixed a small issue where we were not recomputing the oom_adh after finished with
a broadcast.
We no longer instantiate the transport just for the duration of handling a
backup or restore operation. Instead, we hold the object forever (replacing it
if instructed to do so). This makes it easier for transports to watch system
state and help set backup timing policy.
Also fixes up the IBackupTransport documentation a bit.
The 'list sets' and 'restore token#' commands from bmgr now do what they are
supposed to. At this point we see the restore target's data being cleared
properly and its agent being launched and invoked for restore.
This also includes some changes to the window manager permission checks. Almost all of these
are to make it most testable (through an exception on a permission failure), though there is
one permission check that needed to be added: updateOrientationFromAppTokens().
Merge commit '2fdd428e0f18384160f7c38ce3a2cd9ba7e7b2c2'
* commit '2fdd428e0f18384160f7c38ce3a2cd9ba7e7b2c2':
Fix some backup reader/writer issues; make local transport do backup
Fix the jni initializer.
Add RestoreFileHelper, BackupDataInput, and add java wrappers for the methods on BackupDataOutput.
Fix bug #1812041: activity manager crash with bad args.
Journal backup requests so that they won't be lost in a crash
Fix data connection issues.
There was old code that would kill the system process in some cases when there
was a bad activity token. This is really no longer used, except in a few
places where it allows apps to kill the system. So just get rid of it and
make the world a better place.
When an application requests a backup via dataChanged(), we now journal that
fact on disk. The journal persists and is only removed following a successful
backup pass. When the backup manager is started at boot time, it looks for any
existing journal files and schedules a backup for the apps listed in them, on
the expectation that the device shut down or crashed before a backup could be
performed.
Merge commit '9bbc21a773cbdfbef2876a75c32bda5839647751'
* commit '9bbc21a773cbdfbef2876a75c32bda5839647751':
Flesh out restore interface on manager; work up most of LocalTransport
* adding compatibility menu
* backup gravity
* set expanable=true if the screen size is hvga * density.
* added "supports any density" mode. I'll add sdk check later.
* disallow to catch orientation change event if the app is not expandable. This
was causing layout problem under non-expandable mode. I discussed this with Mike C
and we agreed to do this approach for now. We'll revisit if this causes problem to
a lot of applications.
Merge commit 'b81645c868b3d596b5ac56822959feb629a8651e'
* commit 'b81645c868b3d596b5ac56822959feb629a8651e':
ActivityManager: Ensure that we clear the calling process identity around calls to Process.setProcessGroup().
Merge commit 'df01deaacff82b918b4f0ba774d5ad3087543629'
* commit 'df01deaacff82b918b4f0ba774d5ad3087543629':
More restore plumbing, plus add suggested-backoff to transport API
Adds most of the code for a background-thread restore process, structured much
like the backup thread. Broke some common functionality out into a helper
function for doing a synchronous wait for a requested agent to attach.
Added a method to IBackupTransport whereby the transport will be asked for
an opinion on whether this is a good time for a backup to happen. It will
reply with the results of its policymaking around backoff intervals, time-of-day
selection, etc.
We now supply an array of RestoreSet objects instead of wacky Bundle
shenanigans. Also, pushed beginRestoreSession() out to the BackupManager
concrete interface class so that SetupWizard can use it.
(beginRestoreSession() is @hide, non-privileged apps cannot use it. It's
also guarded by android.permission.BACKUP enforcement.)
Restore is a fairly complicated, somewhat stateful process, so we introduce
a new interface to encapsulate the various bits and pieces into a nicely
separable component. In particular, this will make it much cleaner to
open and interrogate an expensive-to-construct transport and then reuse it
for the actual restore process itself.
Instead of just passing a package name to performBackup, pass the whole
PackageInfo struct, explicitly including the list of signatures for the package.
No need to make each transport look this up individually when it's a necessary
part of the backup payload for each app.
Merge commit '19cd309f9eccdf8454dc6e5076013588b7a170a3'
* commit '19cd309f9eccdf8454dc6e5076013588b7a170a3':
Add the EAP related fields for WiFi configuration.