5899 Commits

Author SHA1 Message Date
Jeff Brown
8b65c902ee Merge "Use PARCELABLE_WIRTE_RETURN_VALUE flag in InputChannel. Bug: 5161290" 2011-08-14 20:13:19 -07:00
Adam Powell
40a9784d48 Fix bug 5154361 - New force close dialog text breaks button order rules
Reorder the force close/ANR dialog buttons to better match the new
rules/intent from UX.

Change-Id: I30fed56aabd0cc91d07852807347057176d82aaa
2011-08-14 17:13:10 -07:00
Jeff Brown
0a0ab128a6 Use PARCELABLE_WIRTE_RETURN_VALUE flag in InputChannel.
Bug: 5161290

Replace mDisposeAfterWriteToParcel with code that takes advantage
of the standard Parcel API support for releasing resources after
writing a Binder reply.

This change makes it less likely that InputChannels will leak
accidentally when passed across a Binder.

Change-Id: Id37706e7b88d074e8e4ac687c88f0db8963200f2
2011-08-12 18:08:08 -07:00
Dianne Hackborn
7c0d8472d0 Merge "Fix some crashes that are happening in the system process." 2011-08-12 15:22:32 -07:00
Dianne Hackborn
8e8d65ff5f Fix some crashes that are happening in the system process.
- When shutting down, if the screen goes to sleep there is code
  that tries to do a notifyAll without holding the lock:

java.lang.IllegalMonitorStateException: object not locked by thread before notifyAll()
	at java.lang.Object.notifyAll(Native Method)
	at com.android.server.am.ActivityStack.checkReadyForSleepLocked(ActivityStack.java:776)
	at com.android.server.am.ActivityStack$1.handleMessage(ActivityStack.java:282)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loop(Looper.java:137)
	at com.android.server.ServerThread.run(SystemServer.java:603)

- If an invalid Uri object is sent to the system process it can crash because
  the Uri class throws an assertion while unmarshalling.  Change this to an
  IllegalArgumentException so it gets sent back to the caller:

java.lang.AssertionError
	at android.net.Uri$PathPart.readFrom(Uri.java:2224)
	at android.net.Uri$HierarchicalUri.readFrom(Uri.java:1106)
	at android.net.Uri$1.createFromParcel(Uri.java:1689)
	at android.net.Uri$1.createFromParcel(Uri.java:1681)
	at android.content.IContentService$Stub.onTransact(IContentService.java:53)
	at android.content.ContentService.onTransact(ContentService.java:120)
	at android.os.Binder.execTransact(Binder.java:338)
	at dalvik.system.NativeStart.run(Native Method)

- StrictMode can try to access the first index in the stack crawl of a stack crawl
  array of length 0.  Not sure why this happens, but make the code more robust:

java.lang.ArrayIndexOutOfBoundsException: length=0; index=0
	at android.app.ApplicationErrorReport$CrashInfo.<init>(ApplicationErrorReport.java:341)
	at android.os.StrictMode$ViolationInfo.<init>(StrictMode.java:1978)
	at android.os.StrictMode$AndroidBlockGuardPolicy.startHandlingViolationException(StrictMode.java:1097)
	at android.os.StrictMode$AndroidBlockGuardPolicy.onReadFromDisk(StrictMode.java:1068)
	at libcore.io.BlockGuardOs.read(BlockGuardOs.java:137)
	at libcore.io.IoBridge.read(IoBridge.java:426)
	at java.io.FileInputStream.read(FileInputStream.java:179)
	at java.io.InputStream.read(InputStream.java:148)
	at com.android.internal.os.ProcessStats.readFile(ProcessStats.java:804)
	at com.android.internal.os.ProcessStats.getCpuSpeedTimes(ProcessStats.java:564)
	at com.android.internal.os.ProcessStats.getLastCpuSpeedTimes(ProcessStats.java:545)
	at com.android.server.am.ActivityManagerService.updateCpuStatsNow(ActivityManagerService.java:1470)
	at com.android.server.am.ActivityManagerService.batteryNeedsCpuUpdate(ActivityManagerService.java:1522)
	at com.android.internal.os.BatteryStatsImpl$MyHandler.handleMessage(BatteryStatsImpl.java:110)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loop(Looper.java:137)
	at com.android.server.am.ActivityManagerService$AThread.run(ActivityManagerService.java:1302)

(Also fix this code to not cause strict mode to trigger at all, because there is
no need, because this is just reading stuff from /proc.)

- The system seems to crash during boot if it thinks it needs to rotate
  the screen, when it is trying to take the freeze snapshot way too early.
  There is no need to freeze the screen during boot or if the screen is off:

java.lang.NullPointerException
	at android.view.Surface.init(Native Method)
	at android.view.Surface.<init>(Surface.java:256)
	at com.android.server.wm.ScreenRotationAnimation.<init>(ScreenRotationAnimation.java:91)
	at com.android.server.wm.WindowManagerService.startFreezingDisplayLocked(WindowManagerService.java:8758)
	at com.android.server.wm.WindowManagerService.startAppFreezingScreenLocked(WindowManagerService.java:3971)
	at com.android.server.wm.WindowManagerService.startAppFreezingScreen(WindowManagerService.java:4003)
	at com.android.server.am.ActivityRecord.startFreezingScreenLocked(ActivityRecord.java:515)
	at com.android.server.am.ActivityStack.ensureActivityConfigurationLocked(ActivityStack.java:3997)
	at com.android.server.am.ActivityManagerService.updateConfigurationLocked(ActivityManagerService.java:12535)
	at com.android.server.am.ActivityManagerService.updateConfiguration(ActivityManagerService.java:12439)
	at com.android.server.wm.WindowManagerService.systemReady(WindowManagerService.java:6161)
	at com.android.server.ServerThread.run(SystemServer.java:521)

Change-Id: I85062bb5f6b0909a0f52feedaa75e7611d9d7fbd
2011-08-12 14:20:59 -07:00
Michael Jurka
b858ec559e Merge "On device startup, be in touch mode" 2011-08-11 19:49:15 -07:00
Michael Jurka
e99adc70c8 On device startup, be in touch mode
- Solves bug where an icon showed focus state on startup in Launcher. Once the keyboard arrows are used, Launcher enters non-touch mode as usual

Change-Id: I0080f3b72f6c22833c600a1026af0abc35024510
2011-08-11 18:28:01 -07:00
Christopher Tate
7bc4827e36 Merge "Fix partial-read handling during restore" 2011-08-11 15:07:25 -07:00
Kenny Root
e342551e56 Merge "Better errors from copyResource" 2011-08-11 13:27:10 -07:00
Dianne Hackborn
e09cd7914c Merge "New broadcast telling when an app is fully removed." 2011-08-11 11:35:07 -07:00
Robert Greenwalt
bde7a61a06 Merge "Remove default routes for non-default networks." 2011-08-11 09:55:08 -07:00
Christopher Tate
6853fcf53f Fix partial-read handling during restore
...by once and for all making all of the code deal appropriately with
expected partial reads.  We also now produce a properly conformant
underlying 'tar' EOF sequence [which will be compressed to almost
nothing] to doubly bulletproof the end-of-archive logic.

Fixes bug 5133658

Change-Id: I24a785574861d64ef10fc727b9f6b235575696b0
2011-08-10 17:55:15 -07:00
Jeff Brown
c269dc55f1 Merge "Add input system to Watchdog. Bug: 5094994" 2011-08-10 17:28:15 -07:00
Dianne Hackborn
f9abb40590 New broadcast telling when an app is fully removed.
Change-Id: Ia516d826f302a01881fa92d9ffdc0adfbf669a4b
2011-08-10 17:15:17 -07:00
Kenny Root
f5121a9b80 Better errors from copyResource
Copy resource would fail without a good error code when the file
couldn't be found during copy.

Also destroy the target container ID during move operations since it
might exist. If the copy failed due to it existing, it would get
destroyed anyway. This way the user has a chance to have a good outcome
the first time.

Bug: 3375299
Bug: 5113898
Change-Id: I00559833f0801bc50e7cc031b462495e37a6b4ab
2011-08-10 17:00:30 -07:00
Jeff Brown
89ef0720ee Add input system to Watchdog.
Bug: 5094994

Change-Id: I153866958efc64ac19bda8b997c1c9f6ad425ec4
2011-08-10 16:25:21 -07:00
repo sync
aea743aaa4 P2p enhancements
- ConnectivityService interaction and support for running dhcp server
and client

- State machine enhancements for connectivity interaction

Change-Id: Iba3beb8c87554ffd67a7b7e852bbb4dd8666a4f5
2011-08-10 15:53:49 -07:00
Irfan Sheriff
7244c977ec Ensure interface down before wpa_supplicant start
Now that the driver is built into the kernel, a runtime crash
followed by a driver unload and reload does not reset the interface.

Ensure interface is down before bringing up supplicant

Bug: 5032635
Change-Id: Ib8f3d47617e587139a8a91a82146ee3a2f329700
2011-08-10 15:49:25 -07:00
Jeff Sharkey
fa23c5ae22 Add NativeDaemonConnector users to watchdog.
To catch instances where NativeDaemonConnector hangs while executing
commands, add users to system_server watchdog.  Also moved qtaguid
enabler to separate thread to prevent blocking systemReady().

Bug: 5145437
Change-Id: I4c6c1dc09864a1c05f9486a31faa1b366548e911
2011-08-10 13:42:01 -07:00
Jeff Brown
dbff91077d Merge "Support wrapping app processes to inject debug instrumentation. Bug: 4437846" 2011-08-10 13:41:36 -07:00
Irfan Sheriff
cb30b22ff5 Add firmware reload support for P2P
Refactor firmware reload call to support various modes - AP, STA & P2P

Bug: 5002384
Change-Id: I10d20fe5a7842437cf80861bc8a834990db87db5
2011-08-10 10:18:59 -07:00
Robert Greenwalt
e6b2429cf7 Remove default routes for non-default networks.
Recoding/port of a change that existed in GB but got dropped
in the shuffle.

bug:5036222
Change-Id: I87e819d255c0c46f3ec8fe0fe18d27ae9df1ae36
2011-08-09 16:52:58 -07:00
Jeff Sharkey
05355c3eb6 Enable network stats module by default.
Bug: 5138315
Change-Id: Id4cffdc126bf14a005fc2d3aece87ea036a51999
2011-08-09 14:44:19 -07:00
Kenny Root
e13e48d6fc Merge "Add security checks for new API" 2011-08-09 13:58:26 -07:00
Kenny Root
461ff1f03c Add security checks for new API
Bug: 5137679
Change-Id: Ic0c1e0cf2960a7062ba318b60ee2c92506f6aab6
2011-08-09 11:08:34 -07:00
Dianne Hackborn
a44abeb125 Improve window manager debug output.
Cleaned this up while I was debugging another issue.

Change-Id: I0663b9ed581c6868b59655a0f994d870971ec1a6
2011-08-08 19:24:28 -07:00
Chia-chi Yeh
880f64ac10 Merge "VPN: introduce VpnService as the base class for user space VPN." 2011-08-08 11:33:57 -07:00
Chia-chi Yeh
199ed6ef89 VPN: introduce VpnService as the base class for user space VPN.
Change-Id: I4793a6eb51b33f669fc6d39e1a16cf5eb9e3d851
2011-08-08 11:15:41 -07:00
Mark Brophy
c63502720e Store last-resume times in a separate XML file.
In UsageStatsService, separate last-resume times from the rest of
the statistics, and serialize them to an XML file daily.

This way, ApplicationsProvider will still be able to acces this data,
even thoguh other statistics are flushed to disk and discarded each day.

Bug: 5108745
Change-Id: Id3df3c98243ba02cde16b31e5e29bd9ff3602108
2011-08-08 16:24:16 +01:00
Svetoslav Ganov
74b551aae5 Merge "Turning off accessibility feature reboots the device" 2011-08-08 06:50:19 -07:00
satok
03b2ea1102 Support xml configuration file for the spell checker and add the spell checker subtype
Change-Id: I74715855525fc0a1282238d593ad37aefd42bfc3
2011-08-08 19:29:26 +09:00
Dianne Hackborn
7d608423b7 Move OOM kernel settings to activity manager.
The activity manager now take care of plugging the correct settings
into the OOM killer in the kernel.  This is a lot cleaner because
it is really central to how the activity manager works, and nobody
else cares about them.

Taking advantage of this, the activity manager computes what it
thinks are appropriate OOM levels based on the RAM and display
size of the device.

Also a small optization to the package manager to keep a binding
to the package install helper for a bit after done using it, to
avoid thrashing on it.

And some new APIs that are now needed by Settings.

Change-Id: I2b2d379194445d8305bde331c19bde91c8f24751
2011-08-07 20:20:56 -07:00
Adam Powell
dfee59afb3 Fix bug 5011824 - New Holo overflow menu for physical menu key devices
The new Holo-style overflow menu now appears from the edge of the screen
where the device's physical menu key can be found. The policy determining
this lives in getPreferredOptionsPanelGravity() in WindowManagerService.

Change-Id: I8851a2265547156591e82044e50b5cfc58d3eefa
2011-08-07 14:17:30 -07:00
Daniel Sandler
ffbf1756f6 Merge "Remove notifications when an app is disabled." 2011-08-07 13:37:59 -07:00
Daniel Sandler
aac0eb08bb Remove notifications when an app is disabled.
Bug: 4998840
Change-Id: Ic0c14105924d815aed78da1f5510c98a2fe1dd77
2011-08-06 22:51:56 -04:00
Isaac Levy
8dc6a1b282 Watchdog notify on explicit connect
Notifies when user explicitly clicks on wifi dialog.

Change-Id: I5eee37d68b422d748d41e9384d5006482a223dc5
2011-08-05 20:45:08 -07:00
Dianne Hackborn
9ea3163973 Fix issue #5108980 Wallpaper is not restored after upgrade from IRK32B to IRK33B
Take care of updating from old component name, and don't let this happen
again.

Also tweak how we switch between static wallpapers to avoid introducing
a 4MB allocation in the system UI process when this happens -- we now
stop the current wallpaper service and start a new one, so we get a
brand new surface that we can draw only one time in to.

Change-Id: I6fc8a42b8a46bba79759bd68fb7d0684b5d897b7
2011-08-05 19:22:25 -07:00
Dianne Hackborn
9c181ffbda Merge "Improved memory use reporting." 2011-08-05 18:18:52 -07:00
Dianne Hackborn
b437e090ec Improved memory use reporting.
Change-Id: I38e53e6228bba92a142bafeedb5af8df4e4e5724
2011-08-05 18:18:05 -07:00
Christopher Tate
d37dbc7c96 Merge "Fix bug where sometimes the full backup pw would not be validated" 2011-08-05 15:07:41 -07:00
Wink Saville
fb87cf606a Merge "resolved conflicts for merge of 7bb2d942 to master" 2011-08-05 13:55:39 -07:00
Christopher Tate
eef4ae44b3 Fix bug where sometimes the full backup pw would not be validated
There was a hole where if no backup pw was supplied and the current
pw authentication field was also left blank, it wound up not verifying
and just proceeding with the backup.

Change-Id: I857d8e83cbb2b3bf6b6b04848c5696ef0cf393a1
2011-08-05 13:15:53 -07:00
Wink Saville
2b30afdbad resolved conflicts for merge of 7bb2d942 to master
Change-Id: I026b01805c81d8b26d22e4a195e5e38655a34d32
2011-08-05 11:40:22 -07:00
Irfan Sheriff
d0c3f7e770 Merge "Update scanresult capability check" 2011-08-05 10:21:51 -07:00
Svetoslav Ganov
3e4e4af452 Turning off accessibility feature reboots the device
1. The touch explorer uses delayed injection of events
   which can happen after its hosting accessibility
   input filer has been unregistered, thus the explorer
   was trying to inject events when this is not allowed.
   Now upon unregistration of the accessibility explorer
   it resets the state of the touch explorer it hosts.

bug:5105956

Change-Id: I720682abf93382aedf4f431eaac90fd2c781e442
2011-08-05 07:54:50 -07:00
Svetoslav Ganov
9fbceea01d Merge "ACTION_HOVER_EXIT sometimes not delivered during touch exploration." 2011-08-05 04:59:04 -07:00
satok
0dc8bb25d2 Merge "API cleanup for the spell checker framework" 2011-08-05 03:59:06 -07:00
Irfan Sheriff
fdd5f95a81 Update scanresult capability check
Scan results now have [ESS], [IBSS] & [P2P] to represent an
access point, ad-hoc network & p2p network.

Fix open network check.

Bug: 4998496
Change-Id: I0bf3f168677b0cd8cb27297427b539e768210995
2011-08-04 16:58:33 -07:00
Wink Saville
7bb2d94249 am 090df1dc: Merge "Delay connectivity change notifications." into honeycomb-LTE
* commit '090df1dc4188e5b9ef10a0aca5081a196085ff56':
  Delay connectivity change notifications.
2011-08-04 16:11:41 -07:00
Jeff Sharkey
fe313490fb Merge "Network stats with varint, omit parcel fields." 2011-08-04 15:39:24 -07:00