OSDN Git Service

android-x86/frameworks-native.git
5 years agoMerge "SF: Add multi display layer geometry calculation tests"
TreeHugger Robot [Wed, 6 Mar 2019 23:45:03 +0000 (23:45 +0000)]
Merge "SF: Add multi display layer geometry calculation tests"

5 years agoMerge "Initialize PointerCoords in input tests"
TreeHugger Robot [Wed, 6 Mar 2019 20:18:18 +0000 (20:18 +0000)]
Merge "Initialize PointerCoords in input tests"

5 years agoMerge "SurfaceFlinger: expose idle timer as device config"
TreeHugger Robot [Wed, 6 Mar 2019 19:46:05 +0000 (19:46 +0000)]
Merge "SurfaceFlinger: expose idle timer as device config"

5 years agoMerge "SurfaceFlinger: remove mUse90Hz flag"
TreeHugger Robot [Wed, 6 Mar 2019 18:08:58 +0000 (18:08 +0000)]
Merge "SurfaceFlinger: remove mUse90Hz flag"

5 years agoMerge "SF: fix up DispSync interface"
Kevin DuBois [Wed, 6 Mar 2019 18:00:40 +0000 (18:00 +0000)]
Merge "SF: fix up DispSync interface"

5 years agoMerge "Fix wrong comments of SCRGB in ADataSpace."
TreeHugger Robot [Wed, 6 Mar 2019 12:08:23 +0000 (12:08 +0000)]
Merge "Fix wrong comments of SCRGB in ADataSpace."

5 years agoSurfaceFlinger: expose idle timer as device config
Ady Abraham [Tue, 5 Mar 2019 21:01:13 +0000 (13:01 -0800)]
SurfaceFlinger: expose idle timer as device config

Add a device config for idle timer to allow setting it from
a device.mk file

Bug: 126270036
Test: flashall the build and observe idle timer value
Change-Id: Ic1af3fd20b497a52e9740d898754c0c9eeb223ef

5 years agoSurfaceFlinger: remove mUse90Hz flag
Ady Abraham [Wed, 6 Mar 2019 03:48:12 +0000 (19:48 -0800)]
SurfaceFlinger: remove mUse90Hz flag

As we have now DisplayManager changes in place (b/122905403)
there is no need for mUse90Hz flag. 90Hz will be enabled by
DisplayManager.

Fixes: 126725468
Test: Enable peak refresh from settings
Change-Id: I949727f8ba41bba874ab07160f3f6153d3bf4c67

5 years agoMerge "libbinder_ndk: support dump" am: 36415570df am: 937202b72e
Steven Moreland [Wed, 6 Mar 2019 02:54:27 +0000 (18:54 -0800)]
Merge "libbinder_ndk: support dump" am: 36415570df am: 937202b72e
am: 59183ae588

Change-Id: I1a043b40b5c47048a8a81ad749d93be9d121d903

5 years agoMerge "Clean up libtimeinstate"
TreeHugger Robot [Wed, 6 Mar 2019 02:09:29 +0000 (02:09 +0000)]
Merge "Clean up libtimeinstate"

5 years agoMerge "libbinder_ndk: support dump" am: 36415570df
Steven Moreland [Wed, 6 Mar 2019 01:49:45 +0000 (17:49 -0800)]
Merge "libbinder_ndk: support dump" am: 36415570df
am: 937202b72e

Change-Id: I9ba8f88a15f0bae594ee4b818a5e3afb1459be0c

5 years agoMerge "libbinder_ndk: support dump"
Steven Moreland [Wed, 6 Mar 2019 00:53:57 +0000 (16:53 -0800)]
Merge "libbinder_ndk: support dump"
am: 36415570df

Change-Id: Ice93b194d4990fbd1315b41391bb8f8bcb7f4b55

5 years agoMerge "SF: Rename callbacks from SF to Scheduler to more generic name"
Ana Krulec [Wed, 6 Mar 2019 00:49:19 +0000 (00:49 +0000)]
Merge "SF: Rename callbacks from SF to Scheduler to more generic name"

5 years agoMerge "libbinder_ndk: support dump"
Steven Moreland [Wed, 6 Mar 2019 00:22:37 +0000 (00:22 +0000)]
Merge "libbinder_ndk: support dump"

5 years agoFix wrong comments of SCRGB in ADataSpace.
Peiyong Lin [Tue, 5 Mar 2019 21:50:23 +0000 (13:50 -0800)]
Fix wrong comments of SCRGB in ADataSpace.

BUG: 127511477
Test: N/A
Change-Id: If0f3cbcbbdc5de7be52ce909284238ebf1f3d5cc

5 years agoMerge "SurfaceFlinger: fix sysprop API condition for color management"
TreeHugger Robot [Tue, 5 Mar 2019 21:34:46 +0000 (21:34 +0000)]
Merge "SurfaceFlinger: fix sysprop API condition for color management"

5 years agoMerge "libgui: disable RegionSamplingTest"
Kevin DuBois [Tue, 5 Mar 2019 21:27:12 +0000 (21:27 +0000)]
Merge "libgui: disable RegionSamplingTest"

5 years agolibgui: disable RegionSamplingTest
Kevin DuBois [Tue, 5 Mar 2019 20:47:47 +0000 (12:47 -0800)]
libgui: disable RegionSamplingTest

Test has started failing in presubmit. Disable test to
unblock presubmit while a fix is found.

Bug: 127470525
Test: libgui_test

Change-Id: I2021f4e79b9d2659586274e40b4ed5cac53078f7

5 years agoMerge "[SurfaceFlinger] Add setColorSpaceAgnostic API."
Peiyong Lin [Tue, 5 Mar 2019 20:18:10 +0000 (20:18 +0000)]
Merge "[SurfaceFlinger] Add setColorSpaceAgnostic API."

5 years agoSF: Rename callbacks from SF to Scheduler to more generic name
Ana Krulec [Tue, 5 Mar 2019 18:40:33 +0000 (10:40 -0800)]
SF: Rename callbacks from SF to Scheduler to more generic name

Scheduler is going to call in SF to request configs on more occasions
than just through idle timer. This CL changes the callback into a more
direct request to either switch to DEFAULT or PERFORMANCE config.

Test: manual
Bug: 127365162
Change-Id: I67c37b6679671a9d998fde3fcfd189d572c784b4

5 years agolibbinder_ndk: support dump
Steven Moreland [Tue, 5 Mar 2019 00:47:07 +0000 (16:47 -0800)]
libbinder_ndk: support dump

At the NDK layer:
AIBinder_Class_setOnDump (to implement dump)
AIBinder_dump (to call dump)

At the AIDL layer:
ICInterface::dump(...) to implement and call dump

Bug: 125733384
Test: atest android.binder.cts
Change-Id: I0873ad574bb7a8b9d645c7301fdfa0797e62c834

5 years agoSF: fix up DispSync interface
Kevin DuBois [Wed, 27 Feb 2019 18:05:48 +0000 (10:05 -0800)]
SF: fix up DispSync interface

Delete copy-assign/copy-constructor for pure virtual i/f DispSync
and its related Callback in the DispSync scope.

Test: compile and boot
Fixes: 127471260
Change-Id: I8df533a4f28f80e986c6285d9ae41f35622290a8

5 years agoMerge "SurfaceFlinger: use scheduler::RefreshRateConfigs in setRefreshRateTo"
TreeHugger Robot [Tue, 5 Mar 2019 08:48:27 +0000 (08:48 +0000)]
Merge "SurfaceFlinger: use scheduler::RefreshRateConfigs in setRefreshRateTo"

5 years ago[automerger skipped] Merge "Move PublicFormat from libandroid_runtime to libui" am...
Jooyung Han [Tue, 5 Mar 2019 02:57:45 +0000 (18:57 -0800)]
[automerger skipped] Merge "Move PublicFormat from libandroid_runtime to libui" am: 17f57c6ead am: 6c47c3b982
am: bf98bf8065 -s ours
am skip reason: change_id I7215dde607b425f7a0d47a6541b83fbe3a0deaf4 with SHA1 419fb440fe is in history

Change-Id: I658955f992c2074c55304be175677963555a1e45

5 years agoMerge "Move PublicFormat from libandroid_runtime to libui" am: 17f57c6ead
Jooyung Han [Tue, 5 Mar 2019 02:43:03 +0000 (18:43 -0800)]
Merge "Move PublicFormat from libandroid_runtime to libui" am: 17f57c6ead
am: 6c47c3b982

Change-Id: I9c4ca9b22e050e8fd0f46ff08cdd22a068f8b75c

5 years agoMerge "Move PublicFormat from libandroid_runtime to libui"
Jooyung Han [Tue, 5 Mar 2019 02:29:32 +0000 (18:29 -0800)]
Merge "Move PublicFormat from libandroid_runtime to libui"
am: 17f57c6ead

Change-Id: Ib3fe86fb8c1d2d6726bf4e439f8c8c4ca6ea8619

5 years agoMerge "Move PublicFormat from libandroid_runtime to libui"
Treehugger Robot [Tue, 5 Mar 2019 02:16:42 +0000 (02:16 +0000)]
Merge "Move PublicFormat from libandroid_runtime to libui"

5 years agoMerge "ip-up-vpn: Fix resource leaks in error cases" am: a5d85affa9 am: 01ffab06c1
Greg Kaiser [Tue, 5 Mar 2019 01:21:46 +0000 (17:21 -0800)]
Merge "ip-up-vpn: Fix resource leaks in error cases" am: a5d85affa9 am: 01ffab06c1
am: 44aabf007e

Change-Id: Iae4bef213a1bf1e1a1578afeaa9f550819ac3263

5 years agoMerge "ip-up-vpn: Fix resource leaks in error cases" am: a5d85affa9
Greg Kaiser [Tue, 5 Mar 2019 01:13:32 +0000 (17:13 -0800)]
Merge "ip-up-vpn: Fix resource leaks in error cases" am: a5d85affa9
am: 01ffab06c1

Change-Id: If994d5d43954fb4d87430101c30522f9d100af56

5 years agoMerge "ip-up-vpn: Fix resource leaks in error cases"
Greg Kaiser [Tue, 5 Mar 2019 01:00:24 +0000 (17:00 -0800)]
Merge "ip-up-vpn: Fix resource leaks in error cases"
am: a5d85affa9

Change-Id: Id6a1442dd9226b50a392aca2d484afd357bcabd9

5 years agoMerge "ip-up-vpn: Fix resource leaks in error cases"
Treehugger Robot [Tue, 5 Mar 2019 00:35:12 +0000 (00:35 +0000)]
Merge "ip-up-vpn: Fix resource leaks in error cases"

5 years agoMerge "Get rid of logic that clears sync point when layer is hidden"
Jorim Jaggi [Mon, 4 Mar 2019 22:36:30 +0000 (22:36 +0000)]
Merge "Get rid of logic that clears sync point when layer is hidden"

5 years agoip-up-vpn: Fix resource leaks in error cases
Greg Kaiser [Mon, 4 Mar 2019 22:00:34 +0000 (14:00 -0800)]
ip-up-vpn: Fix resource leaks in error cases

These leaks aren't really consequential since this is a standalone
command, and these "leaks" are in main().  But by putting in simple
fixes for these, we reduce the noise when using static analysis to
find leaks in Android code.

Test: TreeHugger
Change-Id: I2cbb4585c6c8d59a0eb89a72f17dfc4fbc532249

5 years agoSurfaceFlinger: use scheduler::RefreshRateConfigs in setRefreshRateTo
Ady Abraham [Sat, 2 Mar 2019 01:18:59 +0000 (17:18 -0800)]
SurfaceFlinger: use scheduler::RefreshRateConfigs in setRefreshRateTo

Use cached values for display configs instead of querying HWC for the
available configs every time we want to change config.

setRefreshRateTo average time reduced from 0.108 ms to 0.032 ms

Test: collected systrace for config changes
Bug: 122906558
Change-Id: I543973ba01df067bd5ad23a2c2ab48b9a90621ae

5 years ago[SurfaceFlinger] Add setColorSpaceAgnostic API.
Peiyong Lin [Fri, 1 Mar 2019 23:00:23 +0000 (15:00 -0800)]
[SurfaceFlinger] Add setColorSpaceAgnostic API.

Some layers, for example ScreenDecorOverlay*, only carry black, white or gray
with some transpanrency, these values are special as they are color space
agnostic. We don't need to do color conversion on them, instead we want to
intercept the color space before we send to hardware composer for validation.
This patch adds an API to allow this to happen.

BUG: 126616348
Test: Build, flash and boot. Verify by calling in Letterbox.
Change-Id: I62c9bf4feb320b466584a90df707c2b04213339c

5 years agoMerge "Add TEST_MAPPING for atrace"
John Reck [Mon, 4 Mar 2019 18:27:30 +0000 (18:27 +0000)]
Merge "Add TEST_MAPPING for atrace"

5 years agoMerge "Caching between SF and HWC extended to Buffer State Layers"
Valerie Hau [Mon, 4 Mar 2019 17:06:51 +0000 (17:06 +0000)]
Merge "Caching between SF and HWC extended to Buffer State Layers"

5 years agoMerge "dumpstate: handle errors gracefully" am: e953b04799 am: 607ca6029e
Nandana Dutt [Mon, 4 Mar 2019 15:28:54 +0000 (07:28 -0800)]
Merge "dumpstate: handle errors gracefully" am: e953b04799 am: 607ca6029e
am: 995d353cbe

Change-Id: I8c99b22d070227541f2e5ba535ec7f35689c96fd

5 years agoMerge "dumpstate: handle errors gracefully" am: e953b04799
Nandana Dutt [Mon, 4 Mar 2019 15:12:33 +0000 (07:12 -0800)]
Merge "dumpstate: handle errors gracefully" am: e953b04799
am: 607ca6029e

Change-Id: I54463c8a6f238eff4a4b713c510c372c85396cd5

5 years agoMerge "dumpstate: handle errors gracefully"
Nandana Dutt [Mon, 4 Mar 2019 15:09:26 +0000 (07:09 -0800)]
Merge "dumpstate: handle errors gracefully"
am: e953b04799

Change-Id: I6d55aa42a196ac53883057800596b0d065ce605c

5 years agoMerge "dumpstate: handle errors gracefully"
Treehugger Robot [Mon, 4 Mar 2019 14:58:30 +0000 (14:58 +0000)]
Merge "dumpstate: handle errors gracefully"

5 years agoMerge "SF: correct default early phase for high fps"
Midas Chien [Mon, 4 Mar 2019 10:35:01 +0000 (10:35 +0000)]
Merge "SF: correct default early phase for high fps"

5 years agoMove PublicFormat from libandroid_runtime to libui
Jooyung Han [Mon, 4 Mar 2019 07:28:48 +0000 (16:28 +0900)]
Move PublicFormat from libandroid_runtime to libui

PublicFormat is defined in android_view_Surface.
However this and related functions are also used in libmediandk
which is both NDK and LL-NDK. As a LL-NDK it should run without
libandroid_runtime.

By moving PublicFormat definition and its utility functions
into libui, LL-NDK can use it without cost of libandroid_runtime.
And also PublicFormat will be deprecated(b/126594675).

This is a part cutting dependency from libmediandk to
libandroid_runtime.

Note: applied clang-format

Bug: 124268753
Test: m -j
Change-Id: I7215dde607b425f7a0d47a6541b83fbe3a0deaf4
Merged-In: I7215dde607b425f7a0d47a6541b83fbe3a0deaf4

5 years agoMerge "[SurfaceFlinger] Refine expensive rendering trigger."
TreeHugger Robot [Sun, 3 Mar 2019 00:48:28 +0000 (00:48 +0000)]
Merge "[SurfaceFlinger] Refine expensive rendering trigger."

5 years ago[SurfaceFlinger] Refine expensive rendering trigger.
Peiyong Lin [Tue, 15 Jan 2019 03:36:57 +0000 (19:36 -0800)]
[SurfaceFlinger] Refine expensive rendering trigger.

Previously we turned on expensive rendering when color mode is DISPLAY_P3
because wide color gamut implies V0_SCRGB dataspace with FP16 pixel format,
which can't be handled by hardware composer and it's also very expensive in GPU
composition. Now that DISPLAY_P3 color mode doesn't have this implication, we
should move the code to only trigger it if we hit GPU composition in DISPLAY_P3
color mode.

BUG: 114226412
Test: Build, flash and boot.
Test: Verify by modifying WCG to scRGB and checking GPU frequency.
Change-Id: Ia3d3c14574e9ac628497d2f9733e6dd84a2ed01d

5 years agoMerge "Game Driver Metrics: plumb gpu global stats into statsd"
TreeHugger Robot [Sat, 2 Mar 2019 12:01:13 +0000 (12:01 +0000)]
Merge "Game Driver Metrics: plumb gpu global stats into statsd"

5 years agoGame Driver Metrics: plumb gpu global stats into statsd
Yiwei Zhang [Thu, 28 Feb 2019 00:35:37 +0000 (16:35 -0800)]
Game Driver Metrics: plumb gpu global stats into statsd

This change adds all the necessary binder calls to IGpuService.

Bug: 123529932
Test: adb shell cmd stats pull-source 10054
Change-Id: Ibd5b6d366bece45291e80c63f4270c93b56d963f

5 years agoMerge "Ensure we select the right execution binary for all dexopt commands" am: 3e167...
Calin Juravle [Sat, 2 Mar 2019 02:57:30 +0000 (18:57 -0800)]
Merge "Ensure we select the right execution binary for all dexopt commands" am: 3e167da916 am: fefbbd7e13
am: c3608009a9

Change-Id: I30833bd583640650c937cc9d9643fb5b09ad3886

5 years agoMerge "Ensure we select the right execution binary for all dexopt commands" am: 3e167...
Calin Juravle [Sat, 2 Mar 2019 02:53:14 +0000 (18:53 -0800)]
Merge "Ensure we select the right execution binary for all dexopt commands" am: 3e167da916
am: fefbbd7e13

Change-Id: Iee8b97e5bb8d52d7761d3f7748d9a4473d1fa0f3

5 years agoMerge "Ensure we select the right execution binary for all dexopt commands"
Calin Juravle [Sat, 2 Mar 2019 02:49:00 +0000 (18:49 -0800)]
Merge "Ensure we select the right execution binary for all dexopt commands"
am: 3e167da916

Change-Id: I8b32fe8ad5a98e60ca353029cfa6933e59cee315

5 years agoMerge "Ensure we select the right execution binary for all dexopt commands"
Calin Juravle [Sat, 2 Mar 2019 02:36:00 +0000 (02:36 +0000)]
Merge "Ensure we select the right execution binary for all dexopt commands"

5 years agoInitialize PointerCoords in input tests
Siarhei Vishniakou [Thu, 28 Feb 2019 16:16:26 +0000 (08:16 -0800)]
Initialize PointerCoords in input tests

The struct PointerCoords in VelocityTracker_test is created on the
stack, but never initialized. Later, the coords are used to add an x and
y value to the MotionEvent.

The field "bits" in the struct is therefore initialized to whatever was
previously occupying that stack address.
It is possible that stack contained some non-zero data. This would cause
enough of the bits of the 'bits' variable to be set, but without any of
them being X or Y. As a result, when a new X or Y value is assigned, it
does not fit into the bits (there's a 30-axes limit), and therefore
remains at zero.

Later, when velocity is computed, the coordinates evaluate to zero, and
therefore, zero velocity is produced. The test fails, because a non-zero
velocity is expected.

After an audit of the entire Android codebase for usage of
PointerCoords, found another potential issue in InputClassifier_test.
Likely the code was copied over from VelocityTracker_test. Add a fix for
that as well.

Bug: 126536349
Test: atest -it -a libinput_tests, but only executed after building and
flashing asanified libinput and libinput_tests onto device.

Change-Id: Id8b870b6201d7489284bf9fc646750770bb9321a

5 years agoCaching between SF and HWC extended to Buffer State Layers
Valerie Hau [Sat, 2 Mar 2019 00:13:33 +0000 (00:13 +0000)]
Caching between SF and HWC extended to Buffer State Layers

Extend caching to Buffer State Layers and modify slot generation logic
Bug: 120434937
Test: build/boot
Change-Id: Ic74b95c4649b53ad52f4117a464f491cb78715fa

5 years agoSurfaceFlinger: fix sysprop API condition for color management
Daniel Solomon [Sat, 2 Mar 2019 00:27:39 +0000 (16:27 -0800)]
SurfaceFlinger: fix sysprop API condition for color management

Device color management can be set via a dedicated property, or inferred
from two other properties. Currently all 3 properties need to be
specified to *some* value in order for color management to be set as
intended. This fix changes this logic so that if one of the properties
is not specified, the default value for color management is used.

Fixes: 126907354
Test: manual by omitting some of the relevant props from device
makefiles; and atest libsurfaceflinger_unittest

Change-Id: Ic3f76a3e50914906cfd53ec8242dedc2d1585186

5 years agoMerge "Mark Layer as modified when changing zOrderRelativeOf."
Chavi Weingarten [Fri, 1 Mar 2019 23:55:50 +0000 (23:55 +0000)]
Merge "Mark Layer as modified when changing zOrderRelativeOf."

5 years agoAdd TEST_MAPPING for atrace
John Reck [Fri, 1 Mar 2019 18:26:27 +0000 (10:26 -0800)]
Add TEST_MAPPING for atrace

Test: none
Change-Id: Ie0f218b79de85af783c962dc2b981f9648bd41d9

5 years agoEnsure we select the right execution binary for all dexopt commands
Calin Juravle [Fri, 1 Mar 2019 04:29:41 +0000 (20:29 -0800)]
Ensure we select the right execution binary for all dexopt commands

Some devices may not have the debug version of the binaries, so even if we
are asked to use them we can't...

Unify the logic which decides what execution binary to use and apply it to
all commands (dex2oat, profman, dexoptanalyzer).

(follow up fixes to 67a14f6584d6108c29b923ce6a77c0ed5cf347dc)

Test: installd tests
Bug: 124009579
Change-Id: Iec439c0ed63e709cdf35b7f718533eafd429b9c2

5 years agoMerge "Update fence event path for kernel 4.10+" am: f3e024a065 am: 480610413d
Jesse Hall [Fri, 1 Mar 2019 21:20:14 +0000 (13:20 -0800)]
Merge "Update fence event path for kernel 4.10+" am: f3e024a065 am: 480610413d
am: f33fe4c782

Change-Id: Ie9816acdeabf413378ed2a2bc2a299dfeeff2492

5 years agoMerge "Update fence event path for kernel 4.10+" am: f3e024a065
Jesse Hall [Fri, 1 Mar 2019 21:13:00 +0000 (13:13 -0800)]
Merge "Update fence event path for kernel 4.10+" am: f3e024a065
am: 480610413d

Change-Id: If72059250746f9c642d9b0174d9cb15b7dcdaf94

5 years agoMerge "Update fence event path for kernel 4.10+"
Jesse Hall [Fri, 1 Mar 2019 21:07:50 +0000 (13:07 -0800)]
Merge "Update fence event path for kernel 4.10+"
am: f3e024a065

Change-Id: I885b096a6b30e9281293d088595f0b6e66005ae6

5 years agoMerge "Update fence event path for kernel 4.10+"
Treehugger Robot [Fri, 1 Mar 2019 20:56:05 +0000 (20:56 +0000)]
Merge "Update fence event path for kernel 4.10+"

5 years agoMark Layer as modified when changing zOrderRelativeOf.
chaviw [Fri, 1 Mar 2019 18:12:10 +0000 (10:12 -0800)]
Mark Layer as modified when changing zOrderRelativeOf.

If the layer is not marked as modified, the changes will not get copied
from current to drawing. This will break drawing state since it will be
missing info about what a layer is currently relativeOf.

Fixes: 125468401
Test: Can no longer repro issue in bug.
Change-Id: Id75a2bc87c179c4bd11141032acc612e08f0db7b

5 years agoRemove dependency with configstore 1.2
Sundong Ahn [Fri, 22 Feb 2019 02:57:38 +0000 (11:57 +0900)]
Remove dependency with configstore 1.2

The configstore 1.2 is deleted. So cut the dependency with configstore
1.2.

Bug: 124531214
Test: build & boot
Test: adb shell lshal | grep configstore & check configstore 1.2
Change-Id: Ic6b1875e4cf62d45176b83f69a48382c4d9c05c8

5 years agoMerge "Revert "SurfaceFlinger: add stack guards around SurfaceFlinger::postComposition""
TreeHugger Robot [Fri, 1 Mar 2019 05:26:34 +0000 (05:26 +0000)]
Merge "Revert "SurfaceFlinger: add stack guards around SurfaceFlinger::postComposition""

5 years agoMerge "SF: Fix for a leaked mock reported in processesVirtualDisplayAdded"
TreeHugger Robot [Fri, 1 Mar 2019 04:03:01 +0000 (04:03 +0000)]
Merge "SF: Fix for a leaked mock reported in processesVirtualDisplayAdded"

5 years agoMerge "SurfaceFlinger: fix dispatching DISPLAY_EVENT_CONFIG_CHANGED"
TreeHugger Robot [Fri, 1 Mar 2019 03:13:20 +0000 (03:13 +0000)]
Merge "SurfaceFlinger: fix dispatching DISPLAY_EVENT_CONFIG_CHANGED"

5 years agoMerge "Fix ctad-maybe-unsupported warning"
Yi Kong [Fri, 1 Mar 2019 02:09:40 +0000 (02:09 +0000)]
Merge "Fix ctad-maybe-unsupported warning"

5 years agoMerge "Clean up Renderengine caching semantics"
Alec Mouri [Fri, 1 Mar 2019 01:47:14 +0000 (01:47 +0000)]
Merge "Clean up Renderengine caching semantics"

5 years agoRevert "SurfaceFlinger: add stack guards around SurfaceFlinger::postComposition"
Ady Abraham [Fri, 1 Mar 2019 00:08:33 +0000 (16:08 -0800)]
Revert "SurfaceFlinger: add stack guards around SurfaceFlinger::postComposition"

This reverts commit 8164d48b4cb5f27ebb74e7f03875eb2b3b4b89b0.

Test: boot and open some apps
Bug: 122839222
Change-Id: I5ed78c6380a7a96af3c4435f2de1ca40452a71d3

5 years agoMerge "Game Driver Metrics: make gpu stats info parcelable"
TreeHugger Robot [Thu, 28 Feb 2019 23:56:21 +0000 (23:56 +0000)]
Merge "Game Driver Metrics: make gpu stats info parcelable"

5 years agoUpdate fence event path for kernel 4.10+
Jesse Hall [Tue, 26 Feb 2019 00:24:10 +0000 (16:24 -0800)]
Update fence event path for kernel 4.10+

The sysfs path for controlling dma fence events changed yet again in
Linux 4.10, see kernel commit f54d1867005c3.

Test: adb shell atrace --list_categories | grep sync
Test: external/chromium-trace/systrace.py sync, check for dma_fence
      events in trace.html's event list
Change-Id: I45905cf199d5de3d5679151f19f8aa693adea5e1

5 years agoSF: Fix for a leaked mock reported in processesVirtualDisplayAdded
Lloyd Pique [Wed, 27 Feb 2019 00:26:09 +0000 (16:26 -0800)]
SF: Fix for a leaked mock reported in processesVirtualDisplayAdded

I'm not sure why it only started being reported  recently, but removing
the injected virtual display from the SurfaceFlinger current/drawing
state fixes the leak.

Bug: None
Test: adb shell libsurfaceflinger_unittest
Change-Id: Ibaf1a8878e296707b9fbbd0a647908cc1205cdc2

5 years agoGet rid of logic that clears sync point when layer is hidden
Jorim Jaggi [Thu, 28 Feb 2019 22:14:29 +0000 (23:14 +0100)]
Get rid of logic that clears sync point when layer is hidden

For app transitions that go to Launcher, Launcher is initially
hidden, including the leash controlling it as well as the actual
WSA surface. Since the barrier layer of the leash of the closing
app is Launcher WSA, which is a child of the Launcher leash, the
sync point will be cleared because it's not yet shown, as the
showing itself is synced to WSA Launcher surface. However that
destroys the synchronization, leading to jank in various ways.

The justification why this code was added doesn't make sense to
me: SurfaceView usually synchronizes with Activity main window
surfaces. These get destroyed as soon as the activity goes away.
We don't think that logic is needed at all.

Test: Open app, press back, observe no jank
Test: Play video in app
Fixes: 126340236
Change-Id: Ib70d3bbdce1c7206487359213803e3e59d332400

5 years agoClean up Renderengine caching semantics
Alec Mouri [Wed, 20 Feb 2019 03:46:38 +0000 (19:46 -0800)]
Clean up Renderengine caching semantics

* Add unbindExternalTextureBuffer, so that callers such as
BufferLayerConsumer can help manage the cache directly, which improves
system utilization.
* Remove the CacheHint, as it's no longer needed.
* Remove the backing image cache in BufferLayerConsumer, as it has not
been used. We still need a shadow array to properly callback into
RenderEngine, but we no longer need to store EGLImages here.

Bug: 123107664
Test: systrace
Test: open and close apps with GL composition forced, check for buffer
leakage through dumpsys
Change-Id: Ie48f99868dd46a4e18b5d659eea520e97a9eb300

5 years agoFix ctad-maybe-unsupported warning
Yi Kong [Thu, 28 Feb 2019 19:58:32 +0000 (11:58 -0800)]
Fix ctad-maybe-unsupported warning

The upcoming compiler warns about the following code pattern:

frameworks/native/libs/gui/SurfaceComposerClient.cpp:192:5: error: 'lock_guard' may not intend to support class template argument deduction [-Werror,-Wctad-maybe-unsupported]                                                                                                                                                  std::lock_guard lock(mMutex);

Add explicit deduction guide to fix the warning.

Test: m checkbuild
Change-Id: I4b8b22cdd9b9714d0dfc56c1590a19fcdfbbeb07

5 years agoGame Driver Metrics: make gpu stats info parcelable
Yiwei Zhang [Thu, 28 Feb 2019 05:05:06 +0000 (21:05 -0800)]
Game Driver Metrics: make gpu stats info parcelable

This change also rename the GpuStats*Atom to GpuStats*Info because we'd
like to make GpuStats generic to all the authorized recipients, but atom
is too specific to statsd.

Bug: 126560138
Test: adb shell dumpsys gpu --gpustats
Change-Id: Ie071277ae849a32607979d07aca7682febaf4368

5 years agoMerge "Move PublicFormat from libandroid_runtime to libui"
TreeHugger Robot [Thu, 28 Feb 2019 18:44:52 +0000 (18:44 +0000)]
Merge "Move PublicFormat from libandroid_runtime to libui"

5 years agoSurfaceFlinger: fix dispatching DISPLAY_EVENT_CONFIG_CHANGED
Ady Abraham [Thu, 28 Feb 2019 01:05:30 +0000 (17:05 -0800)]
SurfaceFlinger: fix dispatching DISPLAY_EVENT_CONFIG_CHANGED

When setting a new desired config, we might be in the middle of a
previous config changed. We need to maintain the information about
whether we need to generate a config changed event and dispatch it when
we are done with the config switch.

Test: manual test to change config from SF
Bug: 122905403
Change-Id: I7efad63b666e83f6459a65a40e6cc880119ca7f6

5 years agoMerge "SF: Add defensive check on luma sampling"
Sean Callanan [Thu, 28 Feb 2019 18:14:02 +0000 (18:14 +0000)]
Merge "SF: Add defensive check on luma sampling"

5 years agoMerge "Revert "Caching between SF and HWC for BufferStateLayers""
Wale Ogunwale [Thu, 28 Feb 2019 16:03:49 +0000 (16:03 +0000)]
Merge "Revert "Caching between SF and HWC for BufferStateLayers""

5 years agoRevert "Caching between SF and HWC for BufferStateLayers"
Wale Ogunwale [Thu, 28 Feb 2019 15:53:59 +0000 (15:53 +0000)]
Revert "Caching between SF and HWC for BufferStateLayers"

This reverts commit b28f007e51fb84ff78ce8b053d80efb0efdbce20.

Reason for revert: Causing pre-submit failure b/126704033

Change-Id: I17c99cd410b3fa3825d01fedd21a52451368b5c0

5 years agoMerge "Expose allowAudioPlaybackCapture to PackageManagerNative"
Kevin Rocard [Thu, 28 Feb 2019 05:19:58 +0000 (05:19 +0000)]
Merge "Expose allowAudioPlaybackCapture to PackageManagerNative"

5 years agoMerge "SurfaceFlinger: add getAllowedDisplayConfigs"
TreeHugger Robot [Thu, 28 Feb 2019 03:12:18 +0000 (03:12 +0000)]
Merge "SurfaceFlinger: add getAllowedDisplayConfigs"

5 years agoExpose allowAudioPlaybackCapture to PackageManagerNative
Kevin Rocard [Fri, 22 Feb 2019 17:49:24 +0000 (09:49 -0800)]
Expose allowAudioPlaybackCapture to PackageManagerNative

Audio playback has both c++ and java API.
The flag is needed in the audio policy service in c++ to know if the app
can be captured by other apps.

Bug: 119500128
Test: dumpsys media.audio_policy
Change-Id: I949b5e31039b024a34a9646a18586cff5f8807ab
Signed-off-by: Kevin Rocard <krocard@google.com>
5 years agoMerge "Game Driver: dump driver package info in dumpsys gpu"
TreeHugger Robot [Thu, 28 Feb 2019 00:22:50 +0000 (00:22 +0000)]
Merge "Game Driver: dump driver package info in dumpsys gpu"

5 years agoMove PublicFormat from libandroid_runtime to libui
Jooyung Han [Thu, 21 Feb 2019 06:02:58 +0000 (15:02 +0900)]
Move PublicFormat from libandroid_runtime to libui

PublicFormat is defined in android_view_Surface.
However this and related functions are also used in libmediandk
which is both NDK and LL-NDK. As a LL-NDK it should run without
libandroid_runtime.

By moving PublicFormat definition and its utility functions
into libui, LL-NDK can use it without cost of libandroid_runtime.
And also PublicFormat will be deprecated(b/126594675).

This is a part cutting dependency from libmediandk to
libandroid_runtime.

Note: applied clang-format

Bug: 124268753
Test: m -j
Change-Id: I7215dde607b425f7a0d47a6541b83fbe3a0deaf4

5 years agoMerge "Caching between SF and HWC for BufferStateLayers"
Valerie Hau [Wed, 27 Feb 2019 21:45:35 +0000 (21:45 +0000)]
Merge "Caching between SF and HWC for BufferStateLayers"

5 years agoMerge "Remove id from RegionProto object"
Nataniel Borges [Wed, 27 Feb 2019 21:12:36 +0000 (21:12 +0000)]
Merge "Remove id from RegionProto object"

5 years agoSurfaceFlinger: add getAllowedDisplayConfigs
Ady Abraham [Tue, 26 Feb 2019 22:08:03 +0000 (14:08 -0800)]
SurfaceFlinger: add getAllowedDisplayConfigs

Add an API to ISurfaceComposer to get allowed display configurations.

Test: manual test that calls getAllowedDisplayConfigs()
Bug: 122905403
Change-Id: Ieeb04f0d002ecfb2dbb0acd22ef6f659806c3950

5 years agoGame Driver: dump driver package info in dumpsys gpu
Yiwei Zhang [Wed, 27 Feb 2019 19:27:18 +0000 (11:27 -0800)]
Game Driver: dump driver package info in dumpsys gpu

Bug: 126560138
Test: adb shell dumpsys gpu
Change-Id: I7215e68f32a83bc8efa631e296033ea7c7983a34

5 years agoMerge "SF: tidy comments for luma sampling."
TreeHugger Robot [Wed, 27 Feb 2019 17:58:34 +0000 (17:58 +0000)]
Merge "SF: tidy comments for luma sampling."

5 years agodumpstate: handle errors gracefully
Nandana Dutt [Fri, 22 Feb 2019 15:12:35 +0000 (15:12 +0000)]
dumpstate: handle errors gracefully

Return error codes instead of exiting.

Fixes: 123584708
Test: adb shell
/data/nativetest64/dumpstate_smoke_test/dumpstate_smoke_test &&
adb shell /data/nativetest64/dumpstate_test/dumpstate_test

Change-Id: I2b5fcad4e7a7369e02f0c8f5532e0fc69d45480b

5 years agoCaching between SF and HWC for BufferStateLayers
Valerie Hau [Wed, 20 Feb 2019 18:36:29 +0000 (10:36 -0800)]
Caching between SF and HWC for BufferStateLayers

Bug: 120434937
Test: build, boot,libcompositionengine_test
Change-Id: I4a99faeb7aa88683aac19c7000db87bd75f9ebe9

5 years agoSF: Add defensive check on luma sampling
tangrobin [Tue, 26 Feb 2019 10:10:10 +0000 (18:10 +0800)]
SF: Add defensive check on luma sampling

The Add/Remove RegionSamplingListener should return BAD_VALUE
if the input was invalid.

Bug: 119639245
Test: ./libgui_test --gtest_filter="RegionSamplingTest.*"
Change-Id: I5c5f7a30131c52dead970b23230058a62a874902

5 years agoMerge "SurfaceFlinger: fix flakiness in IdleTimerTest"
TreeHugger Robot [Wed, 27 Feb 2019 04:14:44 +0000 (04:14 +0000)]
Merge "SurfaceFlinger: fix flakiness in IdleTimerTest"

5 years agoMerge "[SurfaceFlinger] Add GPU protected content support."
Peiyong Lin [Wed, 27 Feb 2019 02:12:10 +0000 (02:12 +0000)]
Merge "[SurfaceFlinger] Add GPU protected content support."

5 years agoMerge "Game Driver: add GpuStats class to process and dump stats"
TreeHugger Robot [Wed, 27 Feb 2019 01:34:13 +0000 (01:34 +0000)]
Merge "Game Driver: add GpuStats class to process and dump stats"

5 years agoMerge changes I7c51f161,I9231f4b4
TreeHugger Robot [Wed, 27 Feb 2019 00:33:22 +0000 (00:33 +0000)]
Merge changes I7c51f161,I9231f4b4

* changes:
  SF: Remove LayerBE
  SF: Refactor onLayerDisplayed

5 years agoMerge changes from topic "display_policy"
TreeHugger Robot [Wed, 27 Feb 2019 00:01:45 +0000 (00:01 +0000)]
Merge changes from topic "display_policy"

* changes:
  SurfaceFlinger: add DISPLAY_EVENT_CONFIG_CHANGED
  SurfaceFlinger: add setAllowedDisplayConfigs

5 years agoRemove id from RegionProto object
Nataniel Borges [Fri, 15 Feb 2019 23:29:39 +0000 (15:29 -0800)]
Remove id from RegionProto object

The region proto object contains an Id, which is assigned to the memory
address of the Region object.

This information is not necessary on winscope traces, remove.

Test: Flash a device. Collect a SF trace. Open trace in winscope. Check
if Id for region objects is removed from the property list

Change-Id: I4f91745d79d9f1812915836e5e7ac3b416c2052a