OSDN Git Service

android-x86/frameworks-native.git
8 years agoMerge "SF: Fix a couple of Layer ref count issues" into nyc-mr1-dev
Dan Stoza [Tue, 9 Aug 2016 22:29:58 +0000 (22:29 +0000)]
Merge "SF: Fix a couple of Layer ref count issues" into nyc-mr1-dev
am: 1ff2b85b03

Change-Id: Iac13fc45e6b5e5dd469ffd42394aa64a65f3d457

8 years agoSF: Fix a couple of Layer ref count issues
Dan Stoza [Tue, 9 Aug 2016 22:29:58 +0000 (22:29 +0000)]
SF: Fix a couple of Layer ref count issues
am: 92cd24e5f6

Change-Id: Ia62ec102448136979df26ba907bfb1852d4d0373

8 years agoMerge "SF: Fix a couple of Layer ref count issues" into nyc-mr1-dev
Dan Stoza [Tue, 9 Aug 2016 22:25:37 +0000 (22:25 +0000)]
Merge "SF: Fix a couple of Layer ref count issues" into nyc-mr1-dev

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours am:...
Arve Hjnnevg [Tue, 9 Aug 2016 21:24:26 +0000 (21:24 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours am: a82f82293a am: 1c220583e4 am: ce472fbb54  -s ours am: e8cb9c8982 am: 1414d7b372 am: b8d937caeb am: 1864a8748d  -s ours am: a4ef62b859
am: 27f9c82730

Change-Id: I2187dc6218065463b04bdb49a65754ad89ed28b2

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931...
Arve Hjnnevg [Tue, 9 Aug 2016 21:24:26 +0000 (21:24 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931 am: 101c678909  -s ours am: e55418a857 am: 419626b496 am: 12151706b2 am: 899d956cf3  -s ours am: 66818cfeae
am: d3866c201b

Change-Id: If5210c25834538adb53c6f8b8310cfda18c3478e

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours am:...
Arve Hjnnevg [Tue, 9 Aug 2016 21:22:25 +0000 (21:22 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours am: a82f82293a am: 1c220583e4 am: ce472fbb54  -s ours am: e8cb9c8982 am: 1414d7b372 am: b8d937caeb am: 1864a8748d  -s ours
am: a4ef62b859

Change-Id: I471e71c1abbb065d2e3c87671dadbff614fc4a9d

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours am:...
Arve Hjnnevg [Tue, 9 Aug 2016 21:18:53 +0000 (21:18 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours am: a82f82293a am: 1c220583e4 am: ce472fbb54  -s ours am: e8cb9c8982 am: 1414d7b372 am: b8d937caeb
am: 1864a8748d  -s ours

Change-Id: I2e022f5c528ded283a40ad3e3a4ac230070a242b

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931...
Arve Hjnnevg [Tue, 9 Aug 2016 21:16:24 +0000 (21:16 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931 am: 101c678909  -s ours am: e55418a857 am: 419626b496 am: 12151706b2 am: 899d956cf3  -s ours
am: 66818cfeae

Change-Id: Ie8be0fb9b943e5bc8b1046e8e3eb3384e52b223a

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours am:...
Arve Hjnnevg [Tue, 9 Aug 2016 21:16:23 +0000 (21:16 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours am: a82f82293a am: 1c220583e4 am: ce472fbb54  -s ours am: e8cb9c8982 am: 1414d7b372
am: b8d937caeb

Change-Id: I82f6a95334c5c8e484260f120b54ac1d386274da

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours am:...
Arve Hjnnevg [Tue, 9 Aug 2016 21:13:23 +0000 (21:13 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours am: a82f82293a am: 1c220583e4 am: ce472fbb54  -s ours am: e8cb9c8982
am: 1414d7b372

Change-Id: I50541ba686cafded699568f710627bf3e4f8aa1d

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931...
Arve Hjnnevg [Tue, 9 Aug 2016 21:10:26 +0000 (21:10 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931 am: 101c678909  -s ours am: e55418a857 am: 419626b496 am: 12151706b2
am: 899d956cf3  -s ours

Change-Id: I107ec23f410d6ee30603596e4bd4b93c93619791

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours am:...
Arve Hjnnevg [Tue, 9 Aug 2016 21:10:26 +0000 (21:10 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours am: a82f82293a am: 1c220583e4 am: ce472fbb54  -s ours
am: e8cb9c8982

Change-Id: I9445235baf1ea98e3e47af3034fa49b0593ae1b2

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours am:...
Arve Hjnnevg [Tue, 9 Aug 2016 21:07:31 +0000 (21:07 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours am: a82f82293a am: 1c220583e4
am: ce472fbb54  -s ours

Change-Id: I9ac9efe65b6985fc7bd4e7be8a37e471023bd450

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931...
Arve Hjnnevg [Tue, 9 Aug 2016 21:07:23 +0000 (21:07 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931 am: 101c678909  -s ours am: e55418a857 am: 419626b496
am: 12151706b2

Change-Id: I0e550c834f988591d761a1830bee72e99be968f1

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931...
Arve Hjnnevg [Tue, 9 Aug 2016 21:04:24 +0000 (21:04 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931 am: 101c678909  -s ours am: e55418a857
am: 419626b496

Change-Id: Ibe41eb3a2c9a0e28211d546b6b79469bb0523d01

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours am:...
Arve Hjnnevg [Tue, 9 Aug 2016 21:04:24 +0000 (21:04 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours am: a82f82293a
am: 1c220583e4

Change-Id: Ie1ab626a476ecada3ed5171489dc3fec0cf5a1f5

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8 am: a9963dcfb7...
Arve Hjnnevg [Tue, 9 Aug 2016 21:04:23 +0000 (21:04 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8 am: a9963dcfb7 am: cac59eae3b am: 0c63d9490c  -s ours am: cc453b9926
am: 8ea9d9a8f9

Change-Id: I3cbea8b6234ac366ac99dc45f57b54e0ddba1a11

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8 am: a9963dcfb7...
Arve Hjnnevg [Tue, 9 Aug 2016 21:01:24 +0000 (21:01 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8 am: a9963dcfb7 am: cac59eae3b am: 0c63d9490c  -s ours
am: cc453b9926

Change-Id: Ib6cd35f8e1fbabfeca37626854eba9c927b120ca

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36 -s ours
Arve Hjnnevg [Tue, 9 Aug 2016 21:01:23 +0000 (21:01 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: eb304f0a36  -s ours
am: a82f82293a

Change-Id: Ib91d630f70f4fa434915ac15938c7dca94fe3de5

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8 am: a9963dcfb7...
Arve Hjnnevg [Tue, 9 Aug 2016 20:58:24 +0000 (20:58 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8 am: a9963dcfb7 am: cac59eae3b
am: 0c63d9490c  -s ours

Change-Id: I2d17ab94a66c5ee9b5aa7d0bd8a89e31f39d7b9d

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931...
Arve Hjnnevg [Tue, 9 Aug 2016 20:58:24 +0000 (20:58 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931 am: 101c678909  -s ours
am: e55418a857

Change-Id: If0008ff56fb3348ac1bef2c77e99032bf6d51680

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931
Arve Hjnnevg [Tue, 9 Aug 2016 20:55:31 +0000 (20:55 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340 am: 171ab27931
am: 101c678909  -s ours

Change-Id: I3c98fc1516193caab37bcb9cf88ffe6104dd65b1

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check
Arve Hjnnevg [Tue, 9 Aug 2016 20:55:23 +0000 (20:55 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check
am: eb304f0a36  -s ours

Change-Id: I6bae641d0ec80aaba79b716ef8bcd46279aca0ed

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8 am: a9963dcfb7
Arve Hjnnevg [Tue, 9 Aug 2016 20:55:19 +0000 (20:55 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8 am: a9963dcfb7
am: cac59eae3b

Change-Id: I672617263a66261b36de2f3fb6c7829d39f87e51

8 years agoServiceManager: Restore basic uid check am: 2b74d2c1d2
Arve Hjnnevg [Tue, 9 Aug 2016 20:52:19 +0000 (20:52 +0000)]
ServiceManager: Restore basic uid check am: 2b74d2c1d2
am: 3f505a247e

Change-Id: Iae46cadfc90e7f8e13657978fab4e01cefb5b9ba

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8
Arve Hjnnevg [Tue, 9 Aug 2016 20:52:18 +0000 (20:52 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: f03ba2c0d8
am: a9963dcfb7

Change-Id: Id42cd61ca837cc5e9da644feaae10f8f7d0e6c11

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340
Arve Hjnnevg [Tue, 9 Aug 2016 20:49:54 +0000 (20:49 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check am: 247ae46340
am: 171ab27931

Change-Id: I3cfc70e8fb1dd393a92ace283d36ee2b35585ea4

8 years agoServiceManager: Restore basic uid check
Arve Hjnnevg [Tue, 9 Aug 2016 20:49:53 +0000 (20:49 +0000)]
ServiceManager: Restore basic uid check
am: 2b74d2c1d2

Change-Id: I01ebfcff30a8b25e3d8435b96bd437fb6e41f8a5

8 years agoSF: Fix a couple of Layer ref count issues
Dan Stoza [Tue, 9 Aug 2016 20:21:03 +0000 (13:21 -0700)]
SF: Fix a couple of Layer ref count issues

This is an attempt at fixing two reference counting issues for Layers.

The first issue is that since we were holding an sp<IBinder> (really a
reference to a LayerCleaner) inside the layer state for deferred
transactions, there was a possibility that it could end up being the
last strong reference to the LayerCleaner such that when it was
destroyed while applying a non-deferred transaction, it would attempt
to grab the SurfaceFlinger main lock to destroy its Layer. Since this
occurred in the main SurfaceFlinger loop, which was already holding
the lock to process transactions, this would cause a deadlock.

To fix this, the sp<IBinder> inside the layer state was changed to a
wp<IBinder>, only being promoted when it actually needs to be accessed
(i.e., when the deferred transaction is created).

The second issue is that we were promoting and holding a strong
reference to a Layer before calling into SurfaceFlinger to destroy it
on the onLayerDestroyed path (triggered when a LayerCleaner is
destroyed). After returning from the attempt to grab the SurfaceFlinger
main lock, it was possible that this strong reference was the last one
keeping the Layer alive, and destroying it at this point could cause
the HWC2 version of the layer to be destroyed at effectively any point,
even between validate/present.

To fix this, the promotion of the weak Layer reference was moved inside
the critical section where the SurfaceFlinger main lock is held.

Bug: 30503916
Bug: 30281222
Change-Id: I1c6a271f9a7b5d6eea9a9db61d971f262d0cfe84

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check
Arve Hjnnevg [Tue, 9 Aug 2016 20:46:49 +0000 (20:46 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check
am: 247ae46340

Change-Id: I67af781d5876b13daca82cb7e947397c94cd62e7

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check
Arve Hjnnevg [Tue, 9 Aug 2016 20:46:49 +0000 (20:46 +0000)]
DO NOT MERGE ServiceManager: Restore basic uid check
am: f03ba2c0d8

Change-Id: I1435bfcd119116cdd242cf7714ef9535d7abc6fa

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check
Arve Hjønnevåg [Mon, 1 Aug 2016 23:05:17 +0000 (16:05 -0700)]
DO NOT MERGE ServiceManager: Restore basic uid check

Prevent apps from registering services without relying on selinux checks.

Bug: 29431260

Change-Id: I38c6e8bc7f7cba1cbd3568e8fed1ae7ac2054a9b

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check
Arve Hjønnevåg [Mon, 1 Aug 2016 23:05:17 +0000 (16:05 -0700)]
DO NOT MERGE ServiceManager: Restore basic uid check

Prevent apps from registering services without relying on selinux checks.

Bug: 29431260

Change-Id: I38c6e8bc7f7cba1cbd3568e8fed1ae7ac2054a9b

8 years agoDO NOT MERGE ServiceManager: Restore basic uid check
Arve Hjønnevåg [Mon, 1 Aug 2016 23:05:17 +0000 (16:05 -0700)]
DO NOT MERGE ServiceManager: Restore basic uid check

Prevent apps from registering services without relying on selinux checks.

Bug: 29431260

Change-Id: I38c6e8bc7f7cba1cbd3568e8fed1ae7ac2054a9b

8 years agoMerge "Don't use profiles with vm safe mode" into nyc-mr1-dev
Mathieu Chartier [Sat, 6 Aug 2016 02:04:58 +0000 (02:04 +0000)]
Merge "Don't use profiles with vm safe mode" into nyc-mr1-dev
am: cf6e673296

Change-Id: I2a8761cd74641e4cbec312b34536de6f33b50a09

8 years agoDon't use profiles with vm safe mode
Mathieu Chartier [Sat, 6 Aug 2016 02:04:58 +0000 (02:04 +0000)]
Don't use profiles with vm safe mode
am: d46d37b8d4

Change-Id: Ib91e3020496903d43458fee944770744be918e2c

8 years agoMerge "Don't use profiles with vm safe mode" into nyc-mr1-dev
Mathieu Chartier [Sat, 6 Aug 2016 01:56:54 +0000 (01:56 +0000)]
Merge "Don't use profiles with vm safe mode" into nyc-mr1-dev

8 years agoDon't use profiles with vm safe mode
Mathieu Chartier [Sat, 6 Aug 2016 00:48:12 +0000 (17:48 -0700)]
Don't use profiles with vm safe mode

vm safe mode uses interpret only compiler filter, this filter will
generate a full app image if a profile is also passed down. App
image generation without a profile currently has a bug where uses
library is not pruned correctly.

Bug: 30688277

Change-Id: I60d87d698789583b8ab797eb47d031c96caf6d9b
Test: N5X boot, package compile speed-profile comb.BBClient

8 years agoMerge "Tune SensorService thread priority, lower sensor event latency" into nyc-mr1-dev
Peng Xu [Fri, 5 Aug 2016 18:15:39 +0000 (18:15 +0000)]
Merge "Tune SensorService thread priority, lower sensor event latency" into nyc-mr1-dev
am: 283854bb86

Change-Id: Ica343e898b4f0991e8b40e4f5df4198bd592825c

8 years agoTune SensorService thread priority, lower sensor event latency
Peng Xu [Fri, 5 Aug 2016 18:15:38 +0000 (18:15 +0000)]
Tune SensorService thread priority, lower sensor event latency
am: 98d30f627e

Change-Id: Idb637bd13f839550fc8aea115eee074494ae0281

8 years agoMerge "Tune SensorService thread priority, lower sensor event latency" into nyc-mr1-dev
Peng Xu [Fri, 5 Aug 2016 18:03:44 +0000 (18:03 +0000)]
Merge "Tune SensorService thread priority, lower sensor event latency" into nyc-mr1-dev

8 years agoMerge "SF: Change rounding behavior in setGeometry" into nyc-mr1-dev
Pablo Ceballos [Fri, 5 Aug 2016 17:26:25 +0000 (17:26 +0000)]
Merge "SF: Change rounding behavior in setGeometry" into nyc-mr1-dev
am: 6d7d099b8e

Change-Id: Id927602fb53e8043271d607855ec46f01aea53a3

8 years agoSF: Change rounding behavior in setGeometry
Pablo Ceballos [Fri, 5 Aug 2016 17:26:24 +0000 (17:26 +0000)]
SF: Change rounding behavior in setGeometry
am: 51450039e2

Change-Id: I51c03c80fce5cb949e652d21069f5ae50e6588d3

8 years agoMerge "SF: Change rounding behavior in setGeometry" into nyc-mr1-dev
Pablo Ceballos [Fri, 5 Aug 2016 17:14:45 +0000 (17:14 +0000)]
Merge "SF: Change rounding behavior in setGeometry" into nyc-mr1-dev

8 years agoTune SensorService thread priority, lower sensor event latency
Peng Xu [Tue, 2 Aug 2016 01:12:11 +0000 (18:12 -0700)]
Tune SensorService thread priority, lower sensor event latency

Change SensorService priority to SCHED_FIFO 10 to ensure
sensor events to be delivered to apps in consistent short time even
if system is under load.

Bug: 30105910

Change-Id: I5ddf7061b75cf46b54e16476d20bbc888024aa43

8 years agoFixed logic to print BEGIN: line for bugreportz.
Felipe Leme [Thu, 4 Aug 2016 21:55:48 +0000 (21:55 +0000)]
Fixed logic to print BEGIN: line for bugreportz.
am: dcd1f0da54

Change-Id: I8a405fed3457c0472d6ae2dba3ba6864ef2ab79d

8 years agoFixed logic to print BEGIN: line for bugreportz.
Felipe Leme [Thu, 4 Aug 2016 19:48:50 +0000 (12:48 -0700)]
Fixed logic to print BEGIN: line for bugreportz.

BUG: 30451114
Change-Id: I0e65a38999c128a435b43ad0806e06e6e74580ff

8 years agoMerge "Added a BEGIN:path message on bugreportz protocol." into nyc-mr1-dev
Felipe Leme [Thu, 4 Aug 2016 14:51:19 +0000 (14:51 +0000)]
Merge "Added a BEGIN:path message on bugreportz protocol." into nyc-mr1-dev
am: 8329e4cdec

Change-Id: I6197cc612627ad996e6fe1a3da60be28f68809c6

8 years agoAdded a BEGIN:path message on bugreportz protocol.
Felipe Leme [Thu, 4 Aug 2016 14:51:07 +0000 (14:51 +0000)]
Added a BEGIN:path message on bugreportz protocol.
am: aabfcae816

Change-Id: Ied0d630fb2d3380f83c75eb5e8fdacbc4a4f4bbc

8 years agoMerge "Added a BEGIN:path message on bugreportz protocol." into nyc-mr1-dev
TreeHugger Robot [Thu, 4 Aug 2016 14:44:34 +0000 (14:44 +0000)]
Merge "Added a BEGIN:path message on bugreportz protocol." into nyc-mr1-dev

8 years agoSF: Change rounding behavior in setGeometry
Pablo Ceballos [Wed, 3 Aug 2016 17:20:45 +0000 (10:20 -0700)]
SF: Change rounding behavior in setGeometry

- Add an option for a transform to round outwards instead of to the
  nearest pixel.
- Use this new rounding behavior when converting the crop rectangle
  from display-space to layer-space. Otherwise a pixel that will
  partially be on the screen might be marked as transparent.

Bug 30510632

Change-Id: I1aece177cc29c54ee0d4a2c919e47442eb455f30

8 years agoDisable SCHED_FIFO when turning off the display.
Tim Murray [Wed, 3 Aug 2016 01:59:29 +0000 (01:59 +0000)]
Disable SCHED_FIFO when turning off the display.
am: f9d4e44fff

Change-Id: I6eb6ee86174772f9a053505d1fd07b9c2496904f

8 years agoDisable SCHED_FIFO when turning off the display.
Tim Murray [Tue, 2 Aug 2016 22:43:59 +0000 (15:43 -0700)]
Disable SCHED_FIFO when turning off the display.

There can be long SF runtimes when turning the display on or off. Only
use SCHED_FIFO when we are actively going to be rendering frames, not
when turning the display on or off.

bug 30375418

Change-Id: Ibef8e5f3bba0bafc36f92f9f1b299f015fc335f9

8 years agoServiceManager: Restore basic uid check
Arve Hjønnevåg [Mon, 1 Aug 2016 23:05:17 +0000 (16:05 -0700)]
ServiceManager: Restore basic uid check

Prevent apps from registering services without relying on selinux checks.

Bug: 29431260

Change-Id: I38c6e8bc7f7cba1cbd3568e8fed1ae7ac2054a9b

8 years agoAdd gyroscope support to wearable core hw support
Nick Vaccaro [Tue, 2 Aug 2016 16:59:58 +0000 (09:59 -0700)]
Add gyroscope support to wearable core hw support

Add gyroscope to list of wearable's core hardware features since
a gyroscope is a required sensor for Android Wear devices.

Bug: 30151201
Change-Id: Id4db158344b6d1188c71cc5bf787e8bb8cbeca2e

8 years agoAdded a BEGIN:path message on bugreportz protocol.
Felipe Leme [Fri, 29 Jul 2016 16:49:04 +0000 (09:49 -0700)]
Added a BEGIN:path message on bugreportz protocol.

BUG: 30451114
Change-Id: I3607c75b184e71a9a5a6393bdbf68200abe0fc16

8 years agoUpdate SurfaceFlinger FIFO configuration.
Tim Murray [Sun, 31 Jul 2016 21:30:53 +0000 (21:30 +0000)]
Update SurfaceFlinger FIFO configuration.
am: acff43dca6

Change-Id: I15342bd0db918f94aeb5f48d310ff30e3d2a6f56

8 years agoUpdate SurfaceFlinger FIFO configuration.
Tim Murray [Fri, 29 Jul 2016 20:57:24 +0000 (13:57 -0700)]
Update SurfaceFlinger FIFO configuration.

- move SurfaceFlinger main thread to prio 2
- drop EventThread from FIFO but not SFEventThread, which is still FIFO
prio 1
- make DispSyncThread FIFO, prio 1

bug 30481949

Change-Id: Ifedccfbf3cf144ffad030109849a924dddae8d09

8 years agoMerge \"SF: Prime shader cache before boot animation\" into nyc-mr1-dev
Dan Stoza [Fri, 29 Jul 2016 18:53:49 +0000 (18:53 +0000)]
Merge \"SF: Prime shader cache before boot animation\" into nyc-mr1-dev
am: ba5c79ab98

Change-Id: I1a08f74c0c4128835389fa06f65ab9f3d600147d

8 years agoSF: Prime shader cache before boot animation
Dan Stoza [Fri, 29 Jul 2016 18:53:49 +0000 (18:53 +0000)]
SF: Prime shader cache before boot animation
am: 4e63777f75

Change-Id: I6dcd5b280ea8385550d616c274aa21c2df68d3c3

8 years agoMerge "SF: Prime shader cache before boot animation" into nyc-mr1-dev
Dan Stoza [Fri, 29 Jul 2016 18:34:39 +0000 (18:34 +0000)]
Merge "SF: Prime shader cache before boot animation" into nyc-mr1-dev

8 years agodumpsys: fix formatting of service dump times
mukesh agrawal [Thu, 28 Jul 2016 22:02:04 +0000 (22:02 +0000)]
dumpsys: fix formatting of service dump times
am: bca287d284

Change-Id: I55dd6be4e75461a72703560c780b4aff851704a5

8 years agoSF: Prime shader cache before boot animation
Dan Stoza [Thu, 28 Jul 2016 20:31:51 +0000 (13:31 -0700)]
SF: Prime shader cache before boot animation

Primes the shader cache before launching boot animation to avoid
janking when we eventually fall into GLES composition.

Bug: 30040263
Change-Id: I76ba66e92c5e6bb05930c325f384f3b774e91101

8 years agodumpsys: fix formatting of service dump times
mukesh agrawal [Wed, 27 Jul 2016 19:01:49 +0000 (12:01 -0700)]
dumpsys: fix formatting of service dump times

The current formatting of service dump times is
confusing some bugreport parsing tools. This is
because the current service dump time message
is hard to distinguish from the bugreport section
marker.

Adjust the formatting, to make the service
dump time message distinct from the bugreport
section marker.

BUG=30401031
TEST=manual

Manual test
$ adb bugreport /tmp/bugreport.zip
$ cd /tmp
$ mkdir br
$ mv bugreport.zip br
$ cd br
$ grep 'was the duration' bugreport*.txt
------ 4.283s was the duration of 'DUMPSYS MEMINFO' ------
------ 0.053s was the duration of 'DUMPSYS CPUINFO' ------
[...many lines omitted...]
--------- 0.003s was the duration of dumpsys AtCmdFwd
--------- 0.002s was the duration of dumpsys DockObserver
[...many more lines omitted...]

Change-Id: I9d3dd75210b3984240a4b7ab49a1cc6124a269d8
(cherry picked from commit 50b7e039500b3decc78d5ffff9919d1481df4964)

8 years agoMerge \"Build SF executable with USE_HWC2 when needed\" into nyc-mr1-dev
Dan Stoza [Thu, 28 Jul 2016 01:00:41 +0000 (01:00 +0000)]
Merge \"Build SF executable with USE_HWC2 when needed\" into nyc-mr1-dev
am: 98650f0e33

Change-Id: Ie12dc696d3197d472cc9b0e38b3581b057eaf424

8 years agoBuild SF executable with USE_HWC2 when needed
Dan Stoza [Thu, 28 Jul 2016 01:00:40 +0000 (01:00 +0000)]
Build SF executable with USE_HWC2 when needed
am: 10d3fb2360

Change-Id: I8c97bd2ac61eaba8237c1792f1ab7f739bdbd30e

8 years agoMerge "Build SF executable with USE_HWC2 when needed" into nyc-mr1-dev
TreeHugger Robot [Wed, 27 Jul 2016 23:44:27 +0000 (23:44 +0000)]
Merge "Build SF executable with USE_HWC2 when needed" into nyc-mr1-dev

8 years agoBuild SF executable with USE_HWC2 when needed
Dan Stoza [Wed, 27 Jul 2016 22:05:38 +0000 (15:05 -0700)]
Build SF executable with USE_HWC2 when needed

The SurfaceFlinger executable wasn't picking up the USE_HWC2 flag when
enabled by the TARGET_USES_HWC2 BoardConfig, causing a mismatch in the
size of the SurfaceFlinger object. This fixes that by also passing
USE_HWC2 when building the executable.

Bug: 30302693
Change-Id: I1e41e5f548d4b8329590a082d9b69155ba365be9

8 years agoMerge \"HWC2: Clear transform for SolidColor layers\" into nyc-mr1-dev
Dan Stoza [Wed, 27 Jul 2016 21:28:09 +0000 (21:28 +0000)]
Merge \"HWC2: Clear transform for SolidColor layers\" into nyc-mr1-dev
am: 379d2f3528

Change-Id: Ibb49d4f185002d132d72d6dfdbed0b46ac5d6a03

8 years agoHWC2: Clear transform for SolidColor layers
Dan Stoza [Wed, 27 Jul 2016 21:28:09 +0000 (21:28 +0000)]
HWC2: Clear transform for SolidColor layers
am: c6c8954b42

Change-Id: Id3ac783103c22ad9f465985694c1cdac3f9c61d1

8 years agoAdded a -p option to bugreportz to show progress.
Felipe Leme [Wed, 27 Jul 2016 21:28:00 +0000 (21:28 +0000)]
Added a -p option to bugreportz to show progress.
am: 02b7e00c1e

Change-Id: I9151a28d86f63cf7a4795d17761f79f4607571c8

8 years agoAdded unit tests to bugreportz.
Felipe Leme [Wed, 27 Jul 2016 21:27:51 +0000 (21:27 +0000)]
Added unit tests to bugreportz.
am: 59f5af0465

Change-Id: Ide9e2aaac99e7925ec968231b2ed03174fbb08ca

8 years agoMerge "HWC2: Clear transform for SolidColor layers" into nyc-mr1-dev
TreeHugger Robot [Wed, 27 Jul 2016 18:45:54 +0000 (18:45 +0000)]
Merge "HWC2: Clear transform for SolidColor layers" into nyc-mr1-dev

8 years agoHWC2: Clear transform for SolidColor layers
Dan Stoza [Wed, 27 Jul 2016 17:16:52 +0000 (10:16 -0700)]
HWC2: Clear transform for SolidColor layers

Clears the transform for SolidColor layers, since it doesn't make sense
to transform layers without a buffer.

Bug: 30429522
Change-Id: Ib2f4889531556c7ab00e3b270319c321e9f32c84

8 years agoAdded a -p option to bugreportz to show progress.
Felipe Leme [Fri, 22 Jul 2016 19:03:20 +0000 (12:03 -0700)]
Added a -p option to bugreportz to show progress.

BUG: 28609499

Change-Id: I1e60078dfda7e5679fbd19f4981a5dc7a69c4fc7

8 years agoAdded unit tests to bugreportz.
Felipe Leme [Fri, 22 Jul 2016 03:10:57 +0000 (20:10 -0700)]
Added unit tests to bugreportz.

BUG: 28609499

Change-Id: I5b846eeeaa7c05c3e3f66f36d31ef42c472a3099

8 years agoHWC2: Use SolidColor composition for DimLayer
Dan Stoza [Wed, 20 Jul 2016 19:52:38 +0000 (12:52 -0700)]
HWC2: Use SolidColor composition for DimLayer

Switches SurfaceFlinger to try to use SolidColor HWC device
composition for DimLayers instead of always falling back to client
composition.

Bug: 30216498
Change-Id: Ia8af95d214ba72b5657f32f7827a1e6278629f17

8 years agoMerge "BufferQueue consumers: Add discardFreeBuffer method" into nyc-mr1-dev
Eino-Ville Talvala [Fri, 22 Jul 2016 21:42:36 +0000 (21:42 +0000)]
Merge "BufferQueue consumers: Add discardFreeBuffer method" into nyc-mr1-dev

8 years agoMerge "SF: Make screenshot surface async" into nyc-mr1-dev
Pablo Ceballos [Fri, 22 Jul 2016 21:15:43 +0000 (21:15 +0000)]
Merge "SF: Make screenshot surface async" into nyc-mr1-dev

8 years agoMerge changes I7f7d4e0a,Ie966e37d into nyc-mr1-dev
Dan Stoza [Fri, 22 Jul 2016 21:11:15 +0000 (21:11 +0000)]
Merge changes I7f7d4e0a,Ie966e37d into nyc-mr1-dev

* changes:
  HWC2: Check all displays for client composition
  HWC2: Kill logspam for non-HWC virtual displays

8 years agoBufferQueue consumers: Add discardFreeBuffer method
Eino-Ville Talvala [Fri, 22 Jul 2016 00:06:58 +0000 (17:06 -0700)]
BufferQueue consumers: Add discardFreeBuffer method

This method releases all free buffers owned by the buffer queue,
in order to save memory (at the cost of potential future
reallocation of buffers).

Bug: 28695173
Change-Id: I458d10373e639e3144faf673af2ba01aca36e65a

8 years agoMerge "Ignore setxattr() failures on tmpfs." into nyc-mr1-dev
Jeff Sharkey [Fri, 22 Jul 2016 19:09:51 +0000 (19:09 +0000)]
Merge "Ignore setxattr() failures on tmpfs." into nyc-mr1-dev

8 years agoIgnore setxattr() failures on tmpfs.
Jeff Sharkey [Fri, 22 Jul 2016 17:38:54 +0000 (11:38 -0600)]
Ignore setxattr() failures on tmpfs.

Bug: 30210614
Change-Id: Ic9dfb2439b4b1056e1a58552be2e84f4e524321e

8 years agoHWC2: Check all displays for client composition
Dan Stoza [Thu, 21 Jul 2016 21:49:33 +0000 (14:49 -0700)]
HWC2: Check all displays for client composition

SurfaceFlinger currently only checks whether the primary display
performed client composition when considering whether to propagate
backpressure back to apps. This change expands that check to all
displays so that if an external or virtual display is using client
composition it disables backpressure propagation as well.

Bug: 30022738
Change-Id: I7f7d4e0a1ea7d27ef1f280e2b4ebd5e5bd3bd911

8 years agoSF: Make screenshot surface async
Pablo Ceballos [Thu, 21 Jul 2016 20:44:51 +0000 (13:44 -0700)]
SF: Make screenshot surface async

It will only ever have one frame pushed to it and this guarantees that
the late-latching logic will always latch it immediately.

Bug 30209608

Change-Id: I875cb5ea258ebb0afae5d1af4ad946475c2240bc

8 years agoHWC2: Kill logspam for non-HWC virtual displays
Dan Stoza [Thu, 21 Jul 2016 18:09:40 +0000 (11:09 -0700)]
HWC2: Kill logspam for non-HWC virtual displays

Removes some logspam and fixes some non-errors which were reported as
errors when running a virtual display that is not backed by hardware
composer.

Bug: 30022738
Change-Id: Ie966e37d95f53bcc050eef064d24bbe26748b7fd

8 years agoMerge "HWC2: Add properties to revert latching changes" into nyc-mr1-dev
TreeHugger Robot [Thu, 21 Jul 2016 05:27:24 +0000 (05:27 +0000)]
Merge "HWC2: Add properties to revert latching changes" into nyc-mr1-dev

8 years agoHWC2: Add properties to revert latching changes
Dan Stoza [Wed, 20 Jul 2016 22:38:12 +0000 (15:38 -0700)]
HWC2: Add properties to revert latching changes

Adds two properties:

debug.sf.latch_unsignaled - This causes SurfaceFlinger to latch
  buffers even if their fences haven't signaled
debug.sf.disable_backpressure - This causes SurfaceFlinger to skip
  propagating backpressure back to apps by not running when it
  detects that a prior composition missed hardware vsync

Bug: 30216498
Change-Id: Idd70f472ec567a4bc03352f30f201f434cf5d660

8 years agoMerge "Color transforms are now color modes." into nyc-mr1-dev
TreeHugger Robot [Wed, 20 Jul 2016 17:21:33 +0000 (17:21 +0000)]
Merge "Color transforms are now color modes." into nyc-mr1-dev

8 years agoOMX: document time limits for some operations
Lajos Molnar [Tue, 19 Jul 2016 22:31:22 +0000 (15:31 -0700)]
OMX: document time limits for some operations

Bug: 28408062
Bug: 28407319
Change-Id: I7e26eac1d653c871f129b0610e65221b081ba040

8 years agoRegion: Detect malicious overflow in unflatten am: 1a65fccc50 am: fd579a51b5 am:...
Pablo Ceballos [Mon, 18 Jul 2016 22:35:16 +0000 (22:35 +0000)]
Region: Detect malicious overflow in unflatten am: 1a65fccc50 am: fd579a51b5 am: 0e85f4d48d am: 0ec362e024
am: b82c6f52c0

Change-Id: I2aed411154ae53dd27b5f8c76f477afe7136eca3

8 years agoRegion: Detect malicious overflow in unflatten am: 1a65fccc50 am: fd579a51b5 am:...
Pablo Ceballos [Mon, 18 Jul 2016 22:32:55 +0000 (22:32 +0000)]
Region: Detect malicious overflow in unflatten am: 1a65fccc50 am: fd579a51b5 am: 0e85f4d48d
am: 0ec362e024

Change-Id: Ibf1f0aedeab8552fe2a211d01d8b5c2c1ddafcdd

8 years agoRegion: Detect malicious overflow in unflatten am: 1a65fccc50 am: fd579a51b5
Pablo Ceballos [Mon, 18 Jul 2016 22:30:46 +0000 (22:30 +0000)]
Region: Detect malicious overflow in unflatten am: 1a65fccc50 am: fd579a51b5
am: 0e85f4d48d

Change-Id: I6d8ed780a6ec9d8e5b3ec17b20bce528835b4bf0

8 years agoRegion: Detect malicious overflow in unflatten am: 1a65fccc50
Pablo Ceballos [Mon, 18 Jul 2016 22:28:15 +0000 (22:28 +0000)]
Region: Detect malicious overflow in unflatten am: 1a65fccc50
am: fd579a51b5

Change-Id: I2d584199f001f7da8f4331729d796cf527ba79fd

8 years agoRegion: Detect malicious overflow in unflatten
Pablo Ceballos [Mon, 18 Jul 2016 22:25:45 +0000 (22:25 +0000)]
Region: Detect malicious overflow in unflatten
am: 1a65fccc50

Change-Id: I597a130dfe82c21c5611f45f6977b189c0a1a8ea

8 years agoColor transforms are now color modes.
Michael Wright [Tue, 12 Jul 2016 20:30:53 +0000 (13:30 -0700)]
Color transforms are now color modes.

Rename color transforms to color modes for all interfaces exposed to
surfaceflinger clients. Also split it out to be a separate
configuration value from display modes.

Bug: 29044347

Change-Id: I87e937f7c954a50c946e8e2c606797caa416c5d8

8 years agoMerge "Record "cache" inodes to clear while CE is locked." into nyc-mr1-dev
Jeff Sharkey [Fri, 15 Jul 2016 20:53:24 +0000 (20:53 +0000)]
Merge "Record "cache" inodes to clear while CE is locked." into nyc-mr1-dev

8 years agoSF/HWC2: Add support for color transforms
Dan Stoza [Wed, 22 Jun 2016 21:51:09 +0000 (14:51 -0700)]
SF/HWC2: Add support for color transforms

Adds support for color transforms using the setColorTransform method
of HWC2.

This means that instead of always falling back to client composition
when applying a transform, SurfaceFlinger will allow the device to
make that decision. If all layers fall back to client composition, the
SKIP_CLIENT_COLOR_TRANSFORM capability allows the device greater
control over whether SF should apply the transform or whether it
should allow the device to apply it to the client target buffer.

Bug: 19539930
Change-Id: I47a3d5453a3c47a8dd105ab77cce7f9c9687e925

8 years agoRecord "cache" inodes to clear while CE is locked.
Jeff Sharkey [Fri, 15 Jul 2016 00:16:22 +0000 (18:16 -0600)]
Record "cache" inodes to clear while CE is locked.

There are two situations where we need to clear cached data from
all users, including those whose CE storage might still be locked:

1. When PackageManager is clearing caches to try making room for
package updates.
2. When the device fingerprint changes, we need to clear code caches
for all apps.

To enable this, we now record the inode number of the "cache" and
"code_cache" directories in xattrs of the parent directory.  This is
just enough information to find the cache directories to enable
deleting files inside.  When preparing CE storage for an app, we now
create these two directories and immediately write the inode numbers.

Bug: 26056125
Change-Id: I7e442b0676a695acf962593469793a93b03c8aee

8 years agoMerge "HWC2: Fix virtual displays" into nyc-mr1-dev
TreeHugger Robot [Thu, 14 Jul 2016 19:54:21 +0000 (19:54 +0000)]
Merge "HWC2: Fix virtual displays" into nyc-mr1-dev