4647 Commits

Author SHA1 Message Date
Wale Ogunwale
d7fdd0228e Added watchdog monitor for Binder threads availability.
The watchdog will trigger if all binder threads in the system_server
are stuck for a long time (1min) preventing the process from
handling additional IPC requests.

Bug: 19297165
Change-Id: I5909a9c230bf23917feaed53f2b54bd50425bf3c
2015-04-14 21:28:34 -07:00
John Reck
073f36c6c1 Merge "Change how Java Bitmaps are accessed in a few places" 2015-04-13 19:20:59 +00:00
John Reck
a771b9861d Change how Java Bitmaps are accessed in a few places
Stop assuming that a Java Bitmap has a SkBitmap* that
has some externally managed lifecycle, and instead switch
a bunch of users to accessing the bitmap by providing
their own SkBitmap* on which to set the (ref counted!)
SkPixelRef* instead

Change-Id: I0fd9e193968b41e5597784140d56b4885906864a
2015-04-13 09:50:42 -07:00
Prerepa Viswanadham
d4ea01b4ac Merge "Merge commit 'e593d0a' into merge_work" 2015-04-12 21:46:15 +00:00
Andy Hung
00b9bcda8a Merge "Add channel index mask to AudioTrack and AudioFormat" 2015-04-11 06:13:14 +00:00
Andy Hung
4ef1305aa8 Merge "Add floating point AudioRecord read" 2015-04-11 05:44:23 +00:00
Andy Hung
a9470c19a9 Add channel index mask to AudioTrack and AudioFormat
Change-Id: Ia5faa56360edcbbdeae8838ec0f82386f4e5e640
2015-04-10 17:41:00 -07:00
Prerepa Viswanadham
57bf2a8a38 Merge commit 'e593d0a' into merge_work
Change-Id: I4f8ae40fc446cd9cda4d5c6ec99469a98dda595b
2015-04-10 15:58:10 -07:00
John Reck
041a9e5770 Merge "Remove user of GraphicsJNI::createBitmap" 2015-04-10 20:52:51 +00:00
John Reck
4147877b38 Remove user of GraphicsJNI::createBitmap
Change-Id: I2f31bf98ed08eb4bd39a6ce7236c7a23ef309177
2015-04-10 13:35:27 -07:00
Tim Kilbourn
6d85cf2bd7 Simplify input-audio device mapping
Instead of matching on unique ids, allow an .idc file to specify
whether the input device also has a mic.

Bug: 15374820
Change-Id: Ib5f934f1f37f6b98bb906a5be86c6bfa9a5f09c8
2015-04-08 15:44:03 -07:00
Andy Hung
58b0f3f332 Add floating point AudioRecord read
Change-Id: Ibbdbfdefb84b515c231723fb621662bc4920ff86
2015-04-07 12:29:27 -07:00
Raph Levien
3544e6fa56 Merge "Don't use context in measureText(char[])" 2015-04-06 19:21:58 +00:00
Andreas Gampe
305b44b948 am f29be77f: am a4f39ed9: am f8cb672f: Merge "Frameworks/base: Pass variant and feature-set to runtime"
* commit 'f29be77f07084e88ae7104a375a1a54fd91de0dd':
  Frameworks/base: Pass variant and feature-set to runtime
2015-04-04 05:02:27 +00:00
Andreas Gampe
605cca1a98 Frameworks/base: Pass variant and feature-set to runtime
This is required so we pick up the settings correctly when compiling
the boot image on device, or compile any dex files through a
DexClassLoader.

Bug: 20055104
Change-Id: Ia3ab2e48855060894b36f7fd360fe17b978e45a6
2015-04-03 16:08:20 -07:00
Wei Jia
808ba3b5fe Merge "MediaSync: add MediaSync JAVA API" 2015-04-03 22:36:39 +00:00
Wei Jia
071a8b71d1 MediaSync: add MediaSync JAVA API
Bug: 19666434
Change-Id: Iab6941f6d81cb95a3b86be14b239287acb0d0eee
2015-04-03 15:34:34 -07:00
Phil Burk
51ce5c16d5 Merge "audio: add AudioFormat.ENCODING_DTS" 2015-04-03 18:55:05 +00:00
Raph Levien
80b485daa6 Don't use context in measureText(char[])
The measureText(CharSequence) method calls into measureText(char[]),
using a temporary buffer, which may be longer than the CharSequence,
and may have additional characters. The existing implementation was
treating the entire char[] as potential context, but this is
incorrect.

This patch does the measurement on just the substring; measureText
doesn't process context. There are other methods for that, such as
getTextRunAdvances.

Bug: 19962931
Change-Id: Ia00cc004f9fa9d45aaf028683e78404d66c1388f
2015-04-03 10:41:52 -07:00
Raph Levien
f673acb6c9 Merge "Add Paint.hasGlyph method" 2015-04-02 23:27:24 +00:00
Raph Levien
f7f969e67e Add Paint.hasGlyph method
This patch adds a method to determine whether a typeface has a glyph
to support a particular Unicode character or sequence.

The implementation is based on shaping the text and checking for the
presence of .notdef glyphs, and counting the number of glyphs in the
ligature case. In the case of variation selector control characters, it
currently just returns false because there is no variation selector
support yet (Mongolian Free Variation Selectors work because they're
shaped with GSUB instead).

Change-Id: I8ee4ae0d6e81a0ac57f961eb02dcc35aabd87042
2015-04-02 23:14:58 +00:00
Chris Craik
ec3c97d27f Merge "Add compat path for restore underflow" 2015-04-02 22:38:49 +00:00
Chris Craik
3891f3ad59 Add compat path for restore underflow
bug:19829784

Change-Id: Ia761664208ab80c055ca11174db3ddc74457b92b
2015-04-02 15:30:32 -07:00
Paul Jensen
72db88e46f Deprecate static ConnectivityManager.get/setProcessDefaultNetwork() functions.
These functions risk hitting an unchecked Exception due to ConnectivityManager
not being instantiated yet.  Also, change Network.openConnection() to throw a
checked Exception rather than an unchecked Exception when ConnectivityManager
is not yet instantiated.

bug:19416463
Change-Id: Ie1e2b3238aec0343d267c76b64927073f2f05f85
2015-04-02 14:03:43 +00:00
Jim Miller
ebbf205bc6 Prepare to make Fingerprint API public.
- move fingerprint support files into hardware area
- move jni into services/core

Change-Id: I48a8e43d6d328fb66d79919c255e4c44e984b4d1
2015-04-01 19:20:08 -07:00
Eric Laurent
2615afb1b0 audio port: support multiple clients
Add support for more than one audio port callback client per process.

Change-Id: I48051f27fa0b58ce4634b9db46ec8f2aa900398c
2015-04-01 17:31:49 -07:00
Andreas Gampe
ac038f3b69 resolved conflicts for merge of 844e44c9 to master
Change-Id: I8f682da1a50151547f01b4d3a949852525fe6299
2015-04-01 15:57:17 -07:00
Andreas Gampe
e324ba0e7c Frameworks/base: Use system property for cache prune counter
Expose ART's -Xzygote-max-boot-retry through a new system property
dalvik.vm.zygote.max-boot-retry.

Bug: 19983101
Change-Id: Ib88f807e0082d71292c14c7af38e02cca5a5602c
2015-04-01 19:50:58 +00:00
Phil Burk
e12189dee6 audio: add AudioFormat.ENCODING_DTS
Bug: 18292317
Change-Id: I457a6996947d6d24ef7f8f152ee586029036acf5
Signed-off-by: Phil Burk <philburk@google.com>
2015-03-31 14:38:30 -07:00
Raph Levien
b929d65800 Merge "Remove unused constants in android_text_StaticLayout.cpp" 2015-03-31 17:49:31 +00:00
Raph Levien
ee101a3c66 Remove unused constants in android_text_StaticLayout.cpp
The logic for computing line breaking moved to Minikin, and so the
various Unicode characters with special meaning for line breaks are no
longer used in android_text_StaticLayout.cpp (which is now a fairly
thin wrapper that just does JNI glue). This patch deletes the
constants, which makes the warnings-as-errors setting of our current
clang build happy.

Change-Id: I1bb3596ca4f0c78a8e185af9000c0c366fb9b020
2015-03-31 10:42:05 -07:00
Jeff Sharkey
0e9503de20 Merge "Progress towards dynamic storage support." 2015-03-31 04:01:29 +00:00
Andreas Gampe
a60e809994 am abeba1ff: am c10fa20b: am 02c4bbb9: Merge "Frameworks/base: Support dex2oat threads system property"
* commit 'abeba1ff3306eab6ba6e58dce895cd2cf9117700':
  Frameworks/base: Support dex2oat threads system property
2015-03-31 03:44:02 +00:00
Andreas Gampe
e035238823 Frameworks/base: Support dex2oat threads system property
Check dalvik.vm.dex2oat-threads in AndroidRuntime and pass to ART
with "-j" as a compiler option, if found.

Check dalvik.vm.image-dex2oat-threads in AndroidRuntime and pass to
ART with "-j" as an image compiler option, if found.

Bug: 19992386
Change-Id: I5e7806cf560607d31a1d6901dffb14bee538c9cc
2015-03-30 20:16:03 -07:00
Jeff Sharkey
4887789e44 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
2015-03-30 19:46:23 -07:00
Zhijun He
8091ac4cfe Merge "ImageFormat: add PRIVATE format" 2015-03-30 23:46:12 +00:00
Zhijun He
2f17431194 ImageFormat: add PRIVATE format
Bug: 19865019
Change-Id: I1a9335fe1733a5b28d9cb20485b509fb216cb52b
2015-03-30 16:17:35 -07:00
Raph Levien
26d443aee4 Revert "Fix build: Revert "Record hyphens from Minikin and draw them""
This reverts commit 5a6eeb3cbe0896ddf4bdccc0b1a81d7aac49821e and
fixes the underlying issue (needed to @hide getHyphen() for subclasses
of Layout, not just the base class), and layoutlib changes for
checkbuild.

Change-Id: I7a2b5f20ae014ea8e224d8c4079cf9131e17e1c1
2015-03-30 15:13:50 -07:00
Chris Craik
cc6855fc7f Merge "Revert "Avoid throwing ISE in Canvas#restore underflow"" 2015-03-30 20:42:10 +00:00
Ed Heyl
7298d1f079 Merge "Fix build: Revert "Record hyphens from Minikin and draw them"" 2015-03-30 20:35:58 +00:00
Ed Heyl
5a6eeb3cbe Fix build: Revert "Record hyphens from Minikin and draw them"
This reverts commit 27fb878c04e18d3bdd6c42ed347194a7c816ed97.

Change-Id: I2b3390cb0b258a2e1a38ad72ae9686177d6ffdb8
2015-03-30 20:34:02 +00:00
Chris Craik
7d5dda4dca Revert "Avoid throwing ISE in Canvas#restore underflow"
Additionally, rewrite the exception message for clarity.

bug:19951475
bug:19829784

This reverts commit 14cfb6db33264f1c3b127ccf4e45e3ac86527804.

Change-Id: Ie70a49a8d3957025c4b2e47d4ef9f4abd4ded133
2015-03-30 13:31:11 -07:00
John Reck
c74e289a65 Merge "Add GraphicsStatsService" 2015-03-30 19:39:27 +00:00
Raph Levien
683ab2afc5 Merge "Record hyphens from Minikin and draw them" 2015-03-30 19:34:11 +00:00
Christopher Tate
6e6af0d34e Merge "Add payload-size preflight stage to full transport backup" 2015-03-27 23:50:58 +00:00
John Reck
edc524c905 Add GraphicsStatsService
More S's for More Speed

Split JankTracker's backing data from the
class to allow for data relocation to/from ashmem regions

Pack the jank tracking data to fit in 256 bytes

Change-Id: Ife86a64b71a328fbd0c8075fe6a0404e081f725b
2015-03-27 11:50:56 -07:00
Raph Levien
71cbc72e70 Record hyphens from Minikin and draw them
This patch plumbs up hyphens computed in Minikin's LineBreaker,
records them in a new column in StaticLayout, and draws them.
DynamicLayout mirrors the new column, and TextLine is also changed to
make sure the hyphen is only drawn for the last run in a line.

There is a rather primitive mechanism for loading hyphenation
patterns, for testing only at this point.

Change-Id: Ib208568c0f6cff12cf834047500ec1da9ea9f430
2015-03-27 11:13:25 -07:00
Raph Levien
c94f742f7e Calculate line breaks using Minikin
This patch moves the calculation of line breaks for StaticLayout into
the new LineBreaker class provided by Minikin. This specific patch
should preserve existing functionality, but perhaps performance is
better, and the movement opens the door to much more sophisticated
line-breaking.

Change-Id: Iafccb9da4e3559bbeaeb2c7c85f86ddfd8ae2fa1
2015-03-26 22:52:32 -07:00
Christopher Tate
11ae768cf1 Add payload-size preflight stage to full transport backup
We now peform a total-size preflight pass before committing data to the
wire.  This is to eliminate the large superfluous network traffic that
would otherwise happen if the transport enforces internal quotas: we
now instead ask the transport up front whether it's prepared to accept
a given payload size for the package.

From the app's perspective this preflight operation is indistinguishable
from a full-data backup pass.  If the app has provided its own full-data
handling in a subclassed backup agent, their usual file-providing code
path will be executed.  However, the files named for backup during this
pass are not opened and read; just measured for their total size.  As
far as component lifecycles, this measurement pass is simply another
call to the agent, immediately after it is bound, with identical
timeout semantics to the existing full-data backup invocation.

Once the app's file set has been measured the preflight operation
invokes a new method on BackupTransport, called checkFullBackupSize().
This method is called after performFullBackup() (which applies any
overall whitelist/blacklist policy) but before any data is delivered
to the transport via sendBackupData().  The return code from
checkFullBackupSize() is similar to the other transport methods:
TRANSPORT_OK to permit the full backup to proceed; or
TRANSPORT_REJECT_PACKAGE to indicate that the requested payload is
unacceptable; or TRANSPORT_ERROR to report a more serious overall
transport-level problem that prevents a full-data backup operation
from occurring right now.

The estimated payload currently does not include the size of the
source-package metadata (technically, the manifest entry in its
archive payload) or the size of any widget metadata associated with
the package's install.  In practice this means the preflighted size
underestimates by 3 to 5 KB.  In addition, the preflight API currently
cannot distinguish between payload sizes larger than 2 gigabytes;
any payload estimate larger than that is passed as Integer.MAX_VALUE
to the checkFullBackupSize() query.

Bug 19846750

Change-Id: I44498201e2d4b07482dcb3ca8fa6935dddc467ca
2015-03-26 18:57:36 -07:00
Aravind Akella
02bc1fe6b0 Merge "Pipe the packageName of the application from the java layer to SensorService." 2015-03-26 22:17:22 +00:00