summaryrefslogtreecommitdiff
path: root/rs/java/android/renderscript/ProgramVertexFixedFunction.java
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2017-07-05 16:33:56 -0700
committerDianne Hackborn <hackbod@google.com>2017-07-10 17:24:20 +0100
commit3e99f654fbf56d3b7ef7130658b8ef83d2d0cdbd (patch)
tree63e6e0c675b054bd7cf99db591802ee2ffd62e66 /rs/java/android/renderscript/ProgramVertexFixedFunction.java
parentf490ae3e5961a8dfdbd779f0c764b7d44d9d1221 (diff)
Fix issue #34471029: Don't allow audio use from background apps.
This is becoming a common pattern (keeping track of which processes are cached and not allowing them to do stuff in that state), so I am turning this in to a general mechanism for monitoring this state through the activity manager's IUidObserver. Now we can just have AudoService implement its own IUidObserver to get this state and update which uids it is blocking. This required making some changes to uid change reports so that the integer is now a bit mask instead of an enumerations, but that is what it was already turning in to anyway. (This gets rid of the crazy GONE_IDLE constant that we'd needed to add before because it wasn't a bit mask). Eventually the power manager should be changed to be told about these changes to cached state instead of listening to every proc state change, but we'll do that later, it is more disruption than I want to take for now. However, while working on this, I noticed that the power manager had regressed in the cached uids it would actually block, because the activity manager was no longer telling it about all uids that are idle. (I think this happened when I had to change the default idle state of UidRecord to true.) So I am adding a bit of new code to keep track of what idle state we last reported to observers, to make sure we tell it about newly created uids that are idle but have never actually become active. Test: runtest -c com.android.server.am.ActivityManagerServiceTest frameworks-services Change-Id: I7bfd46bacadd4cab2a69f40e6e52afb4e67b456a
Diffstat (limited to 'rs/java/android/renderscript/ProgramVertexFixedFunction.java')
0 files changed, 0 insertions, 0 deletions