summaryrefslogtreecommitdiffstats
path: root/core/jni
Commit message (Collapse)AuthorAgeFilesLines
* am 9a010d0a: Merge "Allow debugging only for apps forked from zygote" into ↵Sebastien Hertz2015-08-181-6/+10
|\ | | | | | | | | | | | | mnc-dev * commit '9a010d0a4157f97870bc38bd3dd0a8f4fd18a172': Allow debugging only for apps forked from zygote
| * Merge "Allow debugging only for apps forked from zygote" into mnc-devSebastien Hertz2015-08-181-6/+10
| |\
| | * Allow debugging only for apps forked from zygoteSebastien Hertz2015-08-101-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When starting the runtime from app_process, we only pass JDWP options if starting zygote. It prevents from opening a JDWP connection in non-zygote programs while Android apps (forked from zygote) remain debuggable. Bug: 23050463 Change-Id: If8ea719063a65db4cdeed69a838b52e87b078b08
* | | am 1017f986: Merge "Camera2: Add camera type to getNumberOfCameras." into ↵Eino-Ville Talvala2015-08-161-0/+6
|\ \ \ | |/ / | | | | | | | | | | | | | | | mnc-dev * commit '1017f9862fb2cdfbff0abe12ef7d20b657a38e36': Camera2: Add camera type to getNumberOfCameras.
| * | Camera2: Add camera type to getNumberOfCameras.Eino-Ville Talvala2015-08-141-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | Do not list strange cameras in old API; ensure new API gets all cameras. Bug: 23194168 Change-Id: Ia1fdffac245525674c913fefb1ec06e9094fe8d3
* | | am bf88205b: Fall back to persist.sys.language/country if locale isn\'t set.Narayan Kamath2015-08-121-27/+59
|\ \ \ | |/ / | | | | | | | | | * commit 'bf88205bef88f78ade5c6830e6203aa343387820': Fall back to persist.sys.language/country if locale isn't set.
| * | Fall back to persist.sys.language/country if locale isn't set.Narayan Kamath2015-08-121-27/+59
| | | | | | | | | | | | | | | | | | | | | | | | This will prevent users from losing their language setting when they take an OTA to M. bug: 23021286 Change-Id: Ifb66f6bf6a940ab745edac709321f3009ec6eab4
* | | am b08c24a3: Frameworks/base: Disable Clang in core/jniAndreas Gampe2015-08-111-0/+4
|\ \ \ | |/ / | | | | | | | | | * commit 'b08c24a3e4f5362bbddc3735802e844e1992cd46': Frameworks/base: Disable Clang in core/jni
| * | Frameworks/base: Disable Clang in core/jniAndreas Gampe2015-08-111-0/+4
| |/ | | | | | | | | | | | | | | thread_local does not work with Clang at the moment. Bug: 22414716 Change-Id: I4059b63a1621c346bfc72dbbec0b9cb165485e26 (cherry picked from commit 2bc67a1b5f9d4662ef7da4645ca8e580302b3553)
* | Merge "camera2: Update DngCreator with bad pixel opcode." into mnc-dr-devRuben Brunk2015-08-071-2/+41
|\ \
| * | camera2: Update DngCreator with bad pixel opcode.Ruben Brunk2015-08-031-2/+41
| | | | | | | | | | | | | | | Bug: 22463079 Change-Id: Id40f02f565d5ce3427479968bc8c3a9e78c04816
* | | am cb54ffb2: Merge "Protect runtime storage mount points." into mnc-devJeff Sharkey2015-08-061-3/+3
|\ \ \ | | |/ | |/| | | | | | | * commit 'cb54ffb2cb9583eaf6b58dcc636681c4e4e07a7d': Protect runtime storage mount points.
| * | Protect runtime storage mount points.Jeff Sharkey2015-08-061-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We have a bunch of magic that mounts the correct view of storage access based on the runtime permissions of an app, but we forgot to protect the real underlying data sources; oops. This series of changes just bumps the directory heirarchy one level to give us /mnt/runtime which we can mask off as 0700 to prevent people from jumping to the exposed internals. Also add CTS tests to verify that we're protecting access to internal mount points like this. Bug: 22964288 Change-Id: I74dbdcb01d4fabe92166b8043a74c6a1e93c6d5f
* | | Add boost to increase the load on newly-forked zygote processes.Tim Murray2015-08-052-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | Makes it more likely for app launches to end up on a large core in an HMP environment. bug 21915482 Change-Id: Ieac192a4bc1237dd03b9492fcad3a78de5510a58
* | | am 7290d93d: Merge "Yell loudly about undefined behind in Bitmap, but work ↵John Reck2015-08-041-1/+0
|\ \ \ | |/ / | | / | |/ |/| | | | | anyway" into mnc-dev * commit '7290d93df99de9d21ac8a9ddf72bc095b319af4b': Yell loudly about undefined behind in Bitmap, but work anyway
| * Yell loudly about undefined behind in Bitmap, but work anywayJohn Reck2015-08-031-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | Bug: 22214367 Previous releases would let the getters on a recycle()'d bitmap to still work despite being firmly in undefined behavior per the documentation on Bitmap#recycle(). As there are apps relying on this, yell very loudly about this behavior in the log and give them a bit of time to fix it Change-Id: I857be7e74cb217877973d9c6f03eb761d12fd056
* | am 7469060e: Merge "Make vendor keys visible in Camera2 java APIs." into mnc-devRuben Brunk2015-08-031-0/+167
|\ \ | |/ | | | | | | * commit '7469060e7855ca5b32f66fbad1a0a4f88737c754': Make vendor keys visible in Camera2 java APIs.
| * Merge "Make vendor keys visible in Camera2 java APIs." into mnc-devRuben Brunk2015-08-031-0/+167
| |\
| | * Make vendor keys visible in Camera2 java APIs.Ruben Brunk2015-07-311-0/+167
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Add vendor keys to getKeys() calls for CameraCharacteristics, CaptureRequest, and CaptureResult. - Vendors can specify whether custom keys show up by listing visible keys in the REQUEST_AVAILABLE_RESULT_KEYS field. - Vendor key types are always treated as a primitive (or Rational) array type corresponding to one of the valid types for a camera metadata entry. Bug: 22067625 Change-Id: I6e7dd3db7a8bf533c2ec15ff69ca38824134e971
* | | Call getInstanceForPackage instead of creating a new SensorManager instance.Aravind Akella2015-07-301-1/+1
|/ / | | | | | | | | Bug: 22529981 Change-Id: If077e042a4af940dfb1fc9c4ac8b9d352dd32685
* | Merge "Revert "Call getInstanceForPackage instead of creating a new ↵Narayan Kamath2015-07-291-1/+1
|\ \ | | | | | | | | | SensorManager instance."" into mnc-dev
| * | Revert "Call getInstanceForPackage instead of creating a new SensorManager ↵Narayan Kamath2015-07-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | instance." This reverts commit 5967ddbf05f146bdb6744207e3daed1aa76fc637. Change-Id: I6d58129585a30d7c2ef39c8cbe796fd696c93f56
* | | Merge "Call getInstanceForPackage instead of creating a new SensorManager ↵Aravind Akella2015-07-291-1/+1
|\ \ \ | |/ / | | | | | | instance." into mnc-dev
| * | Call getInstanceForPackage instead of creating a new SensorManager instance.Aravind Akella2015-07-271-1/+1
| |/ | | | | | | | | Bug: 22529981 Change-Id: Id3adfbcf55d1268db1a555c72a06456a5219c086
* | Merge "Update DngCreator to correctly handle array sizes." into mnc-devRuben Brunk2015-07-281-438/+587
|\ \
| * | Update DngCreator to correctly handle array sizes.Ruben Brunk2015-07-271-438/+587
| |/ | | | | | | | | | | | | | | | | | | | | - Allow both pixelArraySize and preCorrectionArraySize buffer dimensions for input buffers. - Adjust crop, active area, and dimensions used for opcode lists based on the input buffer size. Bug: 22302614 Bug: 22210811 Change-Id: I16fb8921a144b0a251d555037ca45fdc12f7dd18
* | Merge "Fix bitmap get/set pixels for ALPHA_8" into mnc-devChris Craik2015-07-271-0/+21
|\ \
| * | Fix bitmap get/set pixels for ALPHA_8Chris Craik2015-07-241-0/+21
| |/ | | | | | | | | | | bug:22724734 Change-Id: If8307854f6bad6fac9ee0b394bf0b044c61183e5
* | Frameworks/base: Hand fingerprint to ARTAndreas Gampe2015-07-241-0/+7
|/ | | | | | | | To allow ANR dumps to be symbolized easily, hand the build fingerprint to the runtime. Bug: 22693991 Change-Id: Ibd3d3b3bd65dce84acfb97a487807d6f280a9508
* JNI optimization tweaks to Paint high-frequency methodsJohn Reck2015-07-101-8/+6
| | | | | | | | | | | | | | | Bug: 22378829 Use fast-jni for getFontMetrics, drops from 35us -> 30us Note the "heavy" part of the method, getMetricsInternal, is already called by other fast-jni methods. Use critical array access for getRunAdvance_* methods. This will avoid the copy and the access is appropriately scoped and fast enough to not significantly block the moving GC. Improves from 88us -> 79us on short text Change-Id: I7c1481c23f6dba3420fbcf48220f6335cf9f6d10
* Create a thread_local cache for textLocaleJohn Reck2015-07-101-3/+14
| | | | | | | | | | | | | | | Bug:22378829 toLanguageTag is significantly more expensive than previously thought (note ULOC_FULLNAME_CAPACITY is 157) and weighs in at around 40us. Given that this is called on every Paint and that there are typically thousands of Paint objects created this adds up very quickly. Given that the locale is almost always Locale.getDefault(), a very simple thread_local cache of size 1 fixes this trivially Change-Id: I819e60cac7a4b27e9dd5538332c22ce5bbd0851c
* Deep-copying sucks when all you want is a borrowJohn Reck2015-07-092-2/+2
| | | | | | | | | | Bug: 22378829 std::string only knows how to move & deep-copy, and we really don't want either here since the Paint object for certain outlives the stack scope so use a const reference instead. Change-Id: I1c822c6ba9647953899cfe89dcc670d7265e3973
* Clean up get sensorList.Aravind Akella2015-07-011-10/+9
| | | | Change-Id: I46da79cc50b5130a3f21bd567f50b29bf22196f9
* Merge "Changes to Data Injection mode APIs" into mnc-devAravind Akella2015-07-011-7/+5
|\
| * Changes to Data Injection mode APIsAravind Akella2015-06-291-7/+5
| | | | | | | | Change-Id: Id55eaf03656d2d55df7f38d4cac643d97354fe9b
* | Fully unmount existing storage in Zygote.Jeff Sharkey2015-06-301-2/+34
|/ | | | | | | | Before mounting the requested storage into place, fully unmount all existing mounts inherited from the root namespace. Bug: 22192518 Change-Id: I6f7f12c1219d25ee487a031d37c60fb4051d24ad
* Throw DeadObjectException on failed transaction, not RuntimeExceptionChristopher Tate2015-06-291-2/+4
| | | | | | | | | | | In practice we only see failed transactions with small payloads when the remote dies while the binder operation is in flight. Throw the applicable exception type rather than the generic "oops binder went haywire" one. Bug 22104446 Change-Id: I785c15617db7a1f4d505aa11f16e61551c8357ba
* Let's reinvent storage, yet again!Jeff Sharkey2015-06-251-29/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that we're treating storage as a runtime permission, we need to grant read/write access without killing the app. This is really tricky, since we had been using GIDs for access control, and they're set in stone once Zygote drops privileges. The only thing left that can change dynamically is the filesystem itself, so let's do that. This means changing the FUSE daemon to present itself as three different views: /mnt/runtime_default/foo - view for apps with no access /mnt/runtime_read/foo - view for apps with read access /mnt/runtime_write/foo - view for apps with write access There is still a single location for all the backing files, and filesystem permissions are derived the same way for each view, but the file modes are masked off differently for each mountpoint. During Zygote fork, it wires up the appropriate storage access into an isolated mount namespace based on the current app permissions. When the app is granted permissions dynamically at runtime, the system asks vold to jump into the existing mount namespace and bind mount the newly granted access model into place. Bug: 21858077 Change-Id: I62fb25d126dd815aea699b33d580e3afb90f8fd2
* Merge "Don't throw TransactionTooLargeException for small payloads" into mnc-devChristopher Tate2015-06-251-5/+15
|\
| * Don't throw TransactionTooLargeException for small payloadsChristopher Tate2015-06-251-5/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In practice, if we ever see an apparent transaction-too-large result with a modest-sized payload, it means that the remote process died at just the right time (with the binder transaction already in flight so it wasn't detected as a DEAD_OBJECT up front). Don't throw TransactionTooLargeException in this case, because we really do need to distinguish that from dead-remote more accurately. In particular, certain common execution patterns on existing hardware trigger this circumstance, and they wind up crashing the system. This is bad, so now we avoid it unless we're pretty sure that is really what happened. Bug 21801759 Change-Id: Id05f1eecc0d23dc8d0505c402e2cb68396782135
* | Merge "Let findSupportedAbi and hasRenderscriptBitcode scan only relevant ↵Yusuke Sato2015-06-251-12/+4
|\ \ | | | | | | | | | files" into mnc-dev
| * | Let findSupportedAbi and hasRenderscriptBitcode scan only relevant filesYusuke Sato2015-06-221-12/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | for better performance. Without the optimization, these two functions may check more than 100k file names in the pre-installed APK files, which can take a few seconds to finish even on a recent device. Bug: 21957428 Change-Id: I315fd3c6d5aa1076b993752525de449a9933de12
* | | Merge "Frameworks/base: Add tracing system properties" into mnc-devAndreas Gampe2015-06-251-0/+20
|\ \ \
| * | | Frameworks/base: Add tracing system propertiesAndreas Gampe2015-06-221-0/+20
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | Add system properties to support zygote-started method tracing. These are needed as the limit on system properties does not allow the reuse of the runtime extra options system property. Bug: 21760614 Change-Id: I3785cc5715acadbee81ef7b45081ed780f1351d3
* | | Merge "add cpuset support" into mnc-devTim Murray2015-06-242-2/+25
|\ \ \
| * | | add cpuset supportTim Murray2015-06-222-2/+25
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | This moves ActivityManager from using fg/bg cgroups to fg/bg cpusets, which improves load balancing on appropriate devices. bug 21782794 Change-Id: Ife149ea551b8b3611a826566b8c8fc8573fdf654
* | | Make measureText(String, int, int) not use contextRaph Levien2015-06-241-1/+3
| |/ |/| | | | | | | | | | | | | | | | | The measureText method when applied to a string should just measure the substring, rather than treat the entire string as context. It was less likely to cause problems than the similar issues with char arrays, but still wrong. This patch makes the behavior consistent. Bug: 20087437 Change-Id: I1c6e07a694b151f4fb097edae8e271805e996d06
* | Merge "Add missing NULL check for android_os_Parcel_writeInt" into mnc-devBrian Carlstrom2015-06-241-3/+5
|\ \
| * | Add missing NULL check for android_os_Parcel_writeIntBrian Carlstrom2015-06-231-3/+5
| | | | | | | | | | | | | | | | | | | | | All other usages of nativePtr were already checked. Bug: 21636519 Change-Id: Icc09ce4326e6b05c5a248cc4de84ae231d5690b1
* | | Merge "Unify clipping return value behavior - true if not empty" into mnc-devChris Craik2015-06-241-6/+6
|\ \ \