OSDN Git Service

android-x86/frameworks-native.git
11 years agoMerge "Show build config in dumpsys SurfaceFlinger" into jb-mr1-dev
Andy McFadden [Tue, 25 Sep 2012 20:48:15 +0000 (13:48 -0700)]
Merge "Show build config in dumpsys SurfaceFlinger" into jb-mr1-dev

11 years agoMerge "Configure GC free to be 8MB for devices with >512MB RAM." into jb-mr1-dev
Ian Rogers [Tue, 25 Sep 2012 18:36:22 +0000 (11:36 -0700)]
Merge "Configure GC free to be 8MB for devices with >512MB RAM." into jb-mr1-dev

11 years agoShow build config in dumpsys SurfaceFlinger
Andy McFadden [Tue, 25 Sep 2012 02:07:20 +0000 (19:07 -0700)]
Show build config in dumpsys SurfaceFlinger

This adds a line to the "dumpsys SurfaceFlinger" output that shows
build-time configuration values.

Example:
 Build configuration: [sf HAS_CONTEXT_PRIORITY] [libui] \
  [libgui USE_FENCE_SYNC]

Bug 7206633

Change-Id: Ibe1856b459d34a4be6ee83a4ebfd2807e6cc68a0

11 years agofix Layer croping in SurfaceFlinger
Mathias Agopian [Tue, 25 Sep 2012 05:01:01 +0000 (22:01 -0700)]
fix Layer croping in SurfaceFlinger

Bug: 7224628
Change-Id: I9421f0a06b9a27fe00eefaa1dfab8c4309c380c9

11 years agofix a crasher in SurfaceTexture's setFilteringEnabled
Mathias Agopian [Tue, 25 Sep 2012 02:26:11 +0000 (19:26 -0700)]
fix a crasher in SurfaceTexture's setFilteringEnabled

bug: 7211067
Change-Id: Id8658a8df429d76c20ab9112858b38e52343dc9c

11 years agoMerge changes I47cd25c9,I7638ffe8 into jb-mr1-dev
Mathias Agopian [Tue, 25 Sep 2012 01:31:48 +0000 (18:31 -0700)]
Merge changes I47cd25c9,I7638ffe8 into jb-mr1-dev

* changes:
  don't call eglMakeCurrent() before calling HWC commit() on HWC 1.1
  handle EGL errors

11 years agoMerge "EGL: add the EGL_ANDROID_framebuffer_target enum" into jb-mr1-dev
Jamie Gennis [Tue, 25 Sep 2012 01:21:13 +0000 (18:21 -0700)]
Merge "EGL: add the EGL_ANDROID_framebuffer_target enum" into jb-mr1-dev

11 years agoMerge "EGL: expose the EXT_create_context_robustness ext" into jb-mr1-dev
Jamie Gennis [Tue, 25 Sep 2012 01:20:51 +0000 (18:20 -0700)]
Merge "EGL: expose the EXT_create_context_robustness ext" into jb-mr1-dev

11 years agodon't call eglMakeCurrent() before calling HWC commit() on HWC 1.1
Mathias Agopian [Tue, 25 Sep 2012 01:12:35 +0000 (18:12 -0700)]
don't call eglMakeCurrent() before calling HWC commit() on HWC 1.1

this call is not needed and misleading on HWC 1.1; it can also have
a negative performance impact when multiple displays are used.

Bug: 7124069
Change-Id: I47cd25c9d6e69abcc9333b9ecd5044e8fb1919ec

11 years agohandle EGL errors
Mathias Agopian [Tue, 25 Sep 2012 01:07:21 +0000 (18:07 -0700)]
handle EGL errors

for now we just restart the runtime.

bug: 7225248
Change-Id: I7638ffe82075a4db9e7e6f9e35cf48afcb5a387a

11 years agolog an error when eglCreateContext() fails in an inconsistant way
Mathias Agopian [Tue, 25 Sep 2012 00:57:48 +0000 (17:57 -0700)]
log an error when eglCreateContext() fails in an inconsistant way

this will help debugging bug: 7216919

Change-Id: I54ac65f20c5ed55cc93a5cbc5350fadfb0fcb804

11 years agoEGL: add the EGL_ANDROID_framebuffer_target enum
Jamie Gennis [Mon, 24 Sep 2012 20:34:18 +0000 (13:34 -0700)]
EGL: add the EGL_ANDROID_framebuffer_target enum

Change-Id: Id8b1b114e2a7a88956b857c63a0429e9b33fdb5c

11 years agoEGL: expose the EXT_create_context_robustness ext
Jamie Gennis [Thu, 20 Sep 2012 22:47:44 +0000 (15:47 -0700)]
EGL: expose the EXT_create_context_robustness ext

Change-Id: I1db43e96aa5e9e91a6176a4a3e5aa9d1f3ee4a7e

11 years agoMerge "ConsumerBase: make fence names meaningful" into jb-mr1-dev
Jamie Gennis [Mon, 24 Sep 2012 20:36:55 +0000 (13:36 -0700)]
Merge "ConsumerBase: make fence names meaningful" into jb-mr1-dev

11 years agoConsumerBase: make fence names meaningful
Jamie Gennis [Mon, 24 Sep 2012 19:25:15 +0000 (12:25 -0700)]
ConsumerBase: make fence names meaningful

Change-Id: I3580120cb63c027c327e80ec70e68650b75395de

11 years agoConfigure GC free to be 8MB for devices with >512MB RAM.
Ian Rogers [Sun, 23 Sep 2012 23:41:57 +0000 (16:41 -0700)]
Configure GC free to be 8MB for devices with >512MB RAM.

b/6606849

Change-Id: Idad46032b4b5d309db0319caeb7a1dfc0550f9f7

11 years agoMerge "Add android.hardware.camera.any feature to camera permissions." into jb-mr1-dev
Eino-Ville Talvala [Sun, 23 Sep 2012 17:20:53 +0000 (10:20 -0700)]
Merge "Add android.hardware.camera.any feature to camera permissions." into jb-mr1-dev

11 years agoAdd android.hardware.camera.any feature to camera permissions.
Eino-Ville Talvala [Sun, 23 Sep 2012 16:42:12 +0000 (09:42 -0700)]
Add android.hardware.camera.any feature to camera permissions.

Bug: 6847310
Change-Id: I9283932a7c211cd08b3b9fe6a93d8f219e6c9767

11 years agoadd/remove displays properly on hotplug events
Mathias Agopian [Sat, 22 Sep 2012 01:26:16 +0000 (18:26 -0700)]
add/remove displays properly on hotplug events

Bug: 7191563
Change-Id: I8f0fbf3b29658c9479443141798e6f288a1f2d52

11 years agoDisplay events now always carry the display id they happened on
Mathias Agopian [Fri, 21 Sep 2012 06:24:19 +0000 (23:24 -0700)]
Display events now always carry the display id they happened on

Change-Id: I12de1d883c23927722bc3a71b782f0079de4e831

11 years agofix an issue where hotplug events were not dispatched
Mathias Agopian [Fri, 21 Sep 2012 06:14:05 +0000 (23:14 -0700)]
fix an issue where hotplug events were not dispatched

Change-Id: I527eec77f338cd6f1a9021aa4c9d384dbddd6d2a

11 years agoMerge "SurfaceTexture: fix an out of bounds array write" into jb-mr1-dev
Jamie Gennis [Fri, 21 Sep 2012 20:43:23 +0000 (13:43 -0700)]
Merge "SurfaceTexture: fix an out of bounds array write" into jb-mr1-dev

11 years agoMerge "Add a spec for EGL_ANDROID_framebuffer_target." into jb-mr1-dev
Jamie Gennis [Fri, 21 Sep 2012 19:16:37 +0000 (12:16 -0700)]
Merge "Add a spec for EGL_ANDROID_framebuffer_target." into jb-mr1-dev

11 years agoSurfaceTexture: fix an out of bounds array write
Jamie Gennis [Fri, 21 Sep 2012 18:55:35 +0000 (11:55 -0700)]
SurfaceTexture: fix an out of bounds array write

This change fixes an issue causing the mEglContext member of a SurfaceTexture
to get incorrectly zeroed out.  This would happen when a call to
ConsumerBase::releaseBufferLocked resulted in the current buffer being freed.
Freeing the current buffer would set SurfaceTexture::mCurrentTexture to -1,
which would then be used by SurfaceTexture::releaseBufferLocked to reset the
current slot's EGLSyncKHR to EGL_NO_SYNC_KHR (= 0).  This would overwrite the
mEglContext field, resulting in context mismatch errors in
SurfaceTexture::doGLFenceWaitLocked.

The fix is to simply use the buffer slot that's passed in to
SurfaceTexture::releaseBufferLocked rather than mCurrentTexture.

Change-Id: I0e5e2bd88fcbb354c35a3744f317716fff3e0e41

11 years agoAdd a spec for EGL_ANDROID_framebuffer_target.
Jamie Gennis [Thu, 20 Sep 2012 20:55:24 +0000 (13:55 -0700)]
Add a spec for EGL_ANDROID_framebuffer_target.

This change adds a new extension for EGL implementations to indicate the
EGLConfigs that support use as a HWComposer framebuffer target layer.

Change-Id: Ia7c8fbe8da09d57b4ec8bf1d9ddb67ca21aa2885

11 years agoreturn an error, as expected, when querying a disconnected display
Mathias Agopian [Fri, 21 Sep 2012 04:28:12 +0000 (21:28 -0700)]
return an error, as expected, when querying a disconnected display

Change-Id: I405a3a7bb42b9bbd2ec7bfe09e60e1b7acf7389d

11 years agofix a typo preventing pre hwc-1.1 devices from booting
Mathias Agopian [Fri, 21 Sep 2012 02:27:07 +0000 (19:27 -0700)]
fix a typo preventing pre hwc-1.1 devices from booting

Change-Id: Icf01254689633d04967872749ac947a671e47ed8

11 years agowe now correctly set-up connected screens during boot
Mathias Agopian [Thu, 20 Sep 2012 01:16:22 +0000 (18:16 -0700)]
we now correctly set-up connected screens during boot

Change-Id: Ie8b1a3b97ad1821cc970e43abe96c8cec7135b66

11 years agoWe now report hotplug events to the framework
Mathias Agopian [Thu, 20 Sep 2012 00:31:36 +0000 (17:31 -0700)]
We now report hotplug events to the framework

Change-Id: I2d6b7787d39e5929485a551e4982498c5053c211

11 years agoone more step toward HDMI support
Mathias Agopian [Wed, 19 Sep 2012 04:54:42 +0000 (21:54 -0700)]
one more step toward HDMI support

getDisplayInfo() now returns proper information for
HWC managed displays.

hotplug is sitll not supported; so this is not fully correct
as the information returned will be bogus if the HDMI screen
is not plugged in.

Bug: 7191563
Change-Id: If55d8e829fae0443571548155007f486cdf9bc9f

11 years agocalculate wether we filter on a per-display basis
Mathias Agopian [Thu, 20 Sep 2012 06:14:45 +0000 (23:14 -0700)]
calculate wether we filter on a per-display basis

Change-Id: I79d80b432b20b3d02428da19add464ac1e2b9378

11 years agoGraphicBufferAlloc class was declared twice
Mathias Agopian [Thu, 20 Sep 2012 23:54:14 +0000 (16:54 -0700)]
GraphicBufferAlloc class was declared twice

this was confusing because the one in FramebufferSurface
wasn't in fact being used

Change-Id: Ied45aec20d804cfbe52440f9b2f2852a85c757cf

11 years agoMerge "Disable the use of clock_gettime for now." into jb-mr1-dev
Ben Cheng [Thu, 20 Sep 2012 20:17:42 +0000 (13:17 -0700)]
Merge "Disable the use of clock_gettime for now." into jb-mr1-dev

11 years agoMerge "frameworks/native: Amend HDCP API" into jb-mr1-dev
Andreas Huber [Thu, 20 Sep 2012 16:29:41 +0000 (09:29 -0700)]
Merge "frameworks/native: Amend HDCP API" into jb-mr1-dev

11 years agoMerge "Allow 16-bit color EGLConfigs" into jb-mr1-dev
Jesse Hall [Thu, 20 Sep 2012 05:30:55 +0000 (22:30 -0700)]
Merge "Allow 16-bit color EGLConfigs" into jb-mr1-dev

11 years agoam 516efc1b: am 8a2b5423: Merge "libagl: Transform the vertex if using eye space...
Mathias Agopian [Thu, 20 Sep 2012 05:05:14 +0000 (22:05 -0700)]
am 516efc1b: am 8a2b5423: Merge "libagl: Transform the vertex if using eye space lighting with point lights"

* commit '516efc1bea1c05492c5d4636a589cfc686661842':
  libagl: Transform the vertex if using eye space lighting with point lights

11 years agoAllow 16-bit color EGLConfigs
Jesse Hall [Thu, 20 Sep 2012 04:00:49 +0000 (21:00 -0700)]
Allow 16-bit color EGLConfigs

The emulator without GPU acceleration only supports 16-bit
framebuffers.

Bug: 7185810
Change-Id: I883180367bf5b291d5e70427ab586d2e17868a96

11 years agoam 8a2b5423: Merge "libagl: Transform the vertex if using eye space lighting with...
Mathias Agopian [Thu, 20 Sep 2012 03:39:05 +0000 (20:39 -0700)]
am 8a2b5423: Merge "libagl: Transform the vertex if using eye space lighting with point lights"

* commit '8a2b54235a45f92827b13723380065d1ce308236':
  libagl: Transform the vertex if using eye space lighting with point lights

11 years agoMerge "libagl: Transform the vertex if using eye space lighting with point lights"
Mathias Agopian [Thu, 20 Sep 2012 02:31:52 +0000 (19:31 -0700)]
Merge "libagl: Transform the vertex if using eye space lighting with point lights"

11 years agoMerge changes I561c198c,Id4865f3c into jb-mr1-dev
Mathias Agopian [Wed, 19 Sep 2012 23:26:30 +0000 (16:26 -0700)]
Merge changes I561c198c,Id4865f3c into jb-mr1-dev

* changes:
  improve sensor battery usage tracking
  track UID with connections

11 years agofix typo in DisplayDevice logs
Mathias Agopian [Wed, 19 Sep 2012 23:25:29 +0000 (16:25 -0700)]
fix typo in DisplayDevice logs

Change-Id: I593ef674f12073bd9d690946447031394ef9044e

11 years agoDisable the use of clock_gettime for now.
Ben Cheng [Wed, 19 Sep 2012 21:53:10 +0000 (14:53 -0700)]
Disable the use of clock_gettime for now.

Bug: 7100774
Change-Id: I6ede2a37a5d485134fe419b5dc766f70ae4af9d4

11 years agoframeworks/native: Amend HDCP API
Deva Ramasubramanian [Tue, 18 Sep 2012 23:15:32 +0000 (16:15 -0700)]
frameworks/native: Amend HDCP API

- Allow caller to set the observer and cookie.
- Add more notifications that the HDCPModule can send to its Observer.

Change-Id: I8bf9cc02a029cd38bbd25d9f0a634452173f4d26
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
11 years agoimprove sensor battery usage tracking
Mathias Agopian [Wed, 19 Sep 2012 01:49:18 +0000 (18:49 -0700)]
improve sensor battery usage tracking

until now we were tracking when a sensors was
physically enabled or disabled and we were reporting
that to the BattaryService.

this wasn incorrect because we could have several different
apps enabling the same sensor, so the accounting by the
battery service would be incorrect in that case (depending
on the order in which these apps disabled said sensor).

BatteryService tracks sensors per uid, however SensorService
does this per binder connection, so we could have several
binder connections for the same uid, to solve this we keep
a list of sensor/uid -> count, which is the bulk of this
change.

Bug: 6661604
Change-Id: I561c198c42ba1736a8671bdacda4c76d72b9dd6f

11 years agotrack UID with connections
Mathias Agopian [Wed, 19 Sep 2012 00:02:43 +0000 (17:02 -0700)]
track UID with connections

Change-Id: Id4865f3cd27a95acdbbfdff1f2bb4123f312a13b

11 years agoMerge "fix a typo in SensorService" into jb-mr1-dev
Mathias Agopian [Wed, 19 Sep 2012 06:33:20 +0000 (23:33 -0700)]
Merge "fix a typo in SensorService" into jb-mr1-dev

11 years agoMerge "gui: conditionally set USE_NATIVE_FENCE_SYNC for msm8960" into jb-mr1-dev
Iliyan Malchev [Wed, 19 Sep 2012 03:28:04 +0000 (20:28 -0700)]
Merge "gui: conditionally set USE_NATIVE_FENCE_SYNC for msm8960" into jb-mr1-dev

11 years agogui: conditionally set USE_NATIVE_FENCE_SYNC for msm8960
Jeff Boody [Mon, 10 Sep 2012 16:24:07 +0000 (10:24 -0600)]
gui: conditionally set USE_NATIVE_FENCE_SYNC for msm8960

Change-Id: Ib7ad11597ef7c79162a0b0a49a1b8ae16d192c10
Signed-off-by: Iliyan Malchev <malchev@google.com>
11 years agofix a typo in SensorService
Mathias Agopian [Wed, 19 Sep 2012 00:18:54 +0000 (17:18 -0700)]
fix a typo in SensorService

It shouldn't have caused much harm though.
Also log a warning when enabling a sensor
for a connection that is already enabled.

Change-Id: Ia4a052381e79183cd4cb1bedc7ba08e5228d7a38

11 years agoimprove logging of external displays
Mathias Agopian [Tue, 18 Sep 2012 08:38:00 +0000 (01:38 -0700)]
improve logging of external displays

Change-Id: I041aebb7fc655aeca98bbf698d15e05d7c12cac9

11 years agosuppress superfluous log
Mathias Agopian [Tue, 18 Sep 2012 20:19:46 +0000 (13:19 -0700)]
suppress superfluous log

Change-Id: I838f2de4cf99e885833c4f42e2a69d6e3bb8eea5

11 years agoMerge "Check that HWC exists before trying to use it" into jb-mr1-dev
Jesse Hall [Tue, 18 Sep 2012 19:16:13 +0000 (12:16 -0700)]
Merge "Check that HWC exists before trying to use it" into jb-mr1-dev

11 years agoCheck that HWC exists before trying to use it
Jesse Hall [Tue, 18 Sep 2012 18:39:40 +0000 (11:39 -0700)]
Check that HWC exists before trying to use it

Bug: 7185810
Change-Id: I1271d6ba397f3abf0ef166b8d03b9b26b72e28d7

11 years agoSurfaceTexture: default to doing GL sync
Jamie Gennis [Mon, 17 Sep 2012 23:58:17 +0000 (16:58 -0700)]
SurfaceTexture: default to doing GL sync

This change makes updateTexImage default to performing the necessary
synchronization and adds an argument for SurfaceFlinger to disable that
synchronization so that it can be performed lazily.

Change-Id: I7c20923cc786634126fbf7021c9d2541aa77be5d
Bug: 6991805

11 years agoPlumb display name into SurfaceFlinger
Andy McFadden [Tue, 18 Sep 2012 01:27:17 +0000 (18:27 -0700)]
Plumb display name into SurfaceFlinger

The Surface createDisplay() call takes a display name for debugging.
This change carries it through SurfaceFlinger and displays it in
the "dumpsys SurfaceFlinger" output.

Bug 7058158

Change-Id: I79f3474a8656ff1beb7b478e0dbf2c5de666118a

11 years agofix external displays
Mathias Agopian [Tue, 18 Sep 2012 08:21:55 +0000 (01:21 -0700)]
fix external displays

we were not calling eglSwapBuffers() on external displays
because they can't use HWC which caused us to think they
didn't have GLES composition.

Change-Id: I6cef4ae40b138412d2e6f2acda33c9d222b03a83

11 years agoMerge changes I53d70510,If34a05f3 into jb-mr1-dev
Mathias Agopian [Tue, 18 Sep 2012 01:59:04 +0000 (18:59 -0700)]
Merge changes I53d70510,If34a05f3 into jb-mr1-dev

* changes:
  add support hwc 1.1
  refactor things a bit

11 years agoadd support hwc 1.1
Mathias Agopian [Fri, 14 Sep 2012 01:17:13 +0000 (18:17 -0700)]
add support hwc 1.1

Bug: 7124069

Change-Id: I53d705105c4ad8954d3f50ee4f4c8b7ec936b871

11 years agoMerge "EGL: fix an extension string bug" into jb-mr1-dev
Jamie Gennis [Tue, 18 Sep 2012 01:51:55 +0000 (18:51 -0700)]
Merge "EGL: fix an extension string bug" into jb-mr1-dev

11 years agoEGL: fix an extension string bug
Jamie Gennis [Sun, 16 Sep 2012 21:02:20 +0000 (14:02 -0700)]
EGL: fix an extension string bug

This change fixes a bug where initializing EGL multiple times (eglTerminate
followed by eglInitialize) would cause extensions to show up in the extension
string multiple times.

Change-Id: I707a3da62ed30ef13835087167f84a08bc6addd7

11 years agorefactor things a bit
Mathias Agopian [Thu, 13 Sep 2012 21:09:01 +0000 (14:09 -0700)]
refactor things a bit

- decouple GL and main display initialization
- ensure that each "supported" display has its own FramebufferSurface
- onScreenAcquired/Released now takes a display

Change-Id: If34a05f3dea40f6c79db77f4dde283a2580daac4

11 years agoMerge "Use a named constant rather than a magic number." into jb-mr1-dev
Elliott Hughes [Mon, 17 Sep 2012 19:11:24 +0000 (12:11 -0700)]
Merge "Use a named constant rather than a magic number." into jb-mr1-dev

11 years agoUse a named constant rather than a magic number.
Elliott Hughes [Mon, 17 Sep 2012 18:43:40 +0000 (11:43 -0700)]
Use a named constant rather than a magic number.

Change-Id: I86e8c91c6f5628df3eec38faf28598cc8cef2ea3

11 years agoam e917bfbd: am 09a22fc2: Merge "Allow disable of dumpstate vibrate"
jp abgrall [Mon, 17 Sep 2012 18:01:37 +0000 (11:01 -0700)]
am e917bfbd: am 09a22fc2: Merge "Allow disable of dumpstate vibrate"

* commit 'e917bfbd19c265ef09c90f93f5dc175fc62259f5':
  Allow disable of dumpstate vibrate

11 years agoam 09a22fc2: Merge "Allow disable of dumpstate vibrate"
jp abgrall [Mon, 17 Sep 2012 17:58:38 +0000 (10:58 -0700)]
am 09a22fc2: Merge "Allow disable of dumpstate vibrate"

* commit '09a22fc29d588b173e5c0dd2002ac2c44d45b7c6':
  Allow disable of dumpstate vibrate

11 years agoMerge "Allow disable of dumpstate vibrate"
jp abgrall [Mon, 17 Sep 2012 17:21:31 +0000 (10:21 -0700)]
Merge "Allow disable of dumpstate vibrate"

11 years agoAllow disable of dumpstate vibrate
John Michelau [Mon, 17 Sep 2012 16:20:19 +0000 (11:20 -0500)]
Allow disable of dumpstate vibrate

Change-Id: I747b757f4b5e2d6a472b7b2a19f8c1ca8a4b7fdd

11 years agoMerge "Print warnings when backwards timestamps are detected." into jb-mr1-dev
Ben Cheng [Sun, 16 Sep 2012 23:24:28 +0000 (16:24 -0700)]
Merge "Print warnings when backwards timestamps are detected." into jb-mr1-dev

11 years agoPrint warnings when backwards timestamps are detected.
Ben Cheng [Fri, 14 Sep 2012 21:45:34 +0000 (14:45 -0700)]
Print warnings when backwards timestamps are detected.

Bug: 7100774

Change-Id: I752fd1680b32ce33d17d6042d6c82e27d7ba9dd2

11 years agoNew test
Andy McFadden [Sat, 15 Sep 2012 00:21:46 +0000 (17:21 -0700)]
New test

Added a test to confirm that the transform hint is being respected.

Bug: 7162482
Change-Id: I892fe962f8cf2759ff951b4f5065b9ac2732c3d1

11 years agoFix transform hints
Andy McFadden [Fri, 14 Sep 2012 23:10:11 +0000 (16:10 -0700)]
Fix transform hints

The hints were being set a little too late, so the pre-rotation stuff
wasn't quite working.

Bug 7054997

Change-Id: Id8d5c626db7a76f768ba762a145b315878ee08e6

11 years agoFix display projections when translated.
Jeff Brown [Fri, 14 Sep 2012 02:22:41 +0000 (19:22 -0700)]
Fix display projections when translated.

There are two different translations to apply in the logical
orientation, one before scaling and one after.
So translate, scale, translate then rotate.

Bug: 7139798
Change-Id: I0726991cadb62988390e77503dbbaed54f07bfe3

11 years agoMinor tweaks
Andy McFadden [Wed, 12 Sep 2012 23:59:59 +0000 (16:59 -0700)]
Minor tweaks

A couple of minor cleanups I stumbled over while looking at other
things.

Change-Id: I385ecfe1afefd577afbc59d7ef1d98d868073651

11 years agoMerge "Initialize new HWC 1.2 fields" into jb-mr1-dev
Jesse Hall [Thu, 13 Sep 2012 03:18:53 +0000 (20:18 -0700)]
Merge "Initialize new HWC 1.2 fields" into jb-mr1-dev

11 years agoMerge "Fix display projection transforms" into jb-mr1-dev
Jesse Hall [Thu, 13 Sep 2012 03:16:28 +0000 (20:16 -0700)]
Merge "Fix display projection transforms" into jb-mr1-dev

11 years agoMerge "don't call hwc with non-empty layer lists for blanked displays" into jb-mr1-dev
Mathias Agopian [Thu, 13 Sep 2012 02:10:03 +0000 (19:10 -0700)]
Merge "don't call hwc with non-empty layer lists for blanked displays" into jb-mr1-dev

11 years agoRegion::validate() cannot be called from addRectUnchecked()
Mathias Agopian [Thu, 13 Sep 2012 00:56:29 +0000 (17:56 -0700)]
Region::validate() cannot be called from addRectUnchecked()

addRectUnchecked() is allowed to be in an invalid state
temporarily.

Change-Id: I6f5162b5c49f378978c070a77abba35023fe918c

11 years agoMerge "strengthen region validation" into jb-mr1-dev
Mathias Agopian [Thu, 13 Sep 2012 00:49:28 +0000 (17:49 -0700)]
Merge "strengthen region validation" into jb-mr1-dev

11 years agodon't call hwc with non-empty layer lists for blanked displays
Mathias Agopian [Wed, 12 Sep 2012 22:34:57 +0000 (15:34 -0700)]
don't call hwc with non-empty layer lists for blanked displays

we now make sure to take the blanked state of a display into
account when we build its list of visible layers, this ensures
that we won't call prepare/set with a non-empty list when the
display is blanked.

Possibly fixes 7075380710355371301877016215

Bug: 7075380
Change-Id: I9fdd2e73d1b7621eaeca3d4ac2ae60d9fb1b3631

11 years agostrengthen region validation
Mathias Agopian [Wed, 12 Sep 2012 01:56:23 +0000 (18:56 -0700)]
strengthen region validation

Change-Id: I75ee7bc4dd7a2f5357ac8994a23bc8b8bfb6eb44

11 years agoMerge "EGL: make max cache key size BoardConfig-able" into jb-mr1-dev
Jamie Gennis [Wed, 12 Sep 2012 22:54:39 +0000 (15:54 -0700)]
Merge "EGL: make max cache key size BoardConfig-able" into jb-mr1-dev

11 years agoInitialize new HWC 1.2 fields
Jesse Hall [Fri, 7 Sep 2012 18:20:56 +0000 (11:20 -0700)]
Initialize new HWC 1.2 fields

Also rename resolution* to width/height.

Change-Id: Ia5f0c50d3f0a349160f314a3257c3b985e13ef1d

11 years agoFix display projection transforms
Jesse Hall [Wed, 12 Sep 2012 20:49:10 +0000 (13:49 -0700)]
Fix display projection transforms

Bug: 7139798
Change-Id: I61aafe99180d85563c6880d16bc367fce80e6022

11 years agoMerge "Fix emulator" into jb-mr1-dev
Andy McFadden [Wed, 12 Sep 2012 20:27:00 +0000 (13:27 -0700)]
Merge "Fix emulator" into jb-mr1-dev

11 years agoMerge "Watch for SurfaceFlinger death" into jb-mr1-dev
Andy McFadden [Wed, 12 Sep 2012 20:22:35 +0000 (13:22 -0700)]
Merge "Watch for SurfaceFlinger death" into jb-mr1-dev

11 years agoFix emulator
Andy McFadden [Wed, 12 Sep 2012 20:14:51 +0000 (13:14 -0700)]
Fix emulator

Emulator has no HWC.

Change-Id: I7810b27034f6772823142e5bf877681db1c8ee49

11 years agoEGL: make max cache key size BoardConfig-able
Jamie Gennis [Wed, 12 Sep 2012 18:55:16 +0000 (11:55 -0700)]
EGL: make max cache key size BoardConfig-able

This change makes the maximum EGL blob cache key size configurable via a
BoardConfig.

Change-Id: Ic669cd25fc743662bd4f13aab62354fc3d54560c

11 years agoMerge "SurfaceTexture: eglDestroySync after duping its fd" into jb-mr1-dev
Jamie Gennis [Wed, 12 Sep 2012 18:54:52 +0000 (11:54 -0700)]
Merge "SurfaceTexture: eglDestroySync after duping its fd" into jb-mr1-dev

11 years agoMerge "fix typo in LayerBase::dump()" into jb-mr1-dev
Mathias Agopian [Wed, 12 Sep 2012 03:53:20 +0000 (20:53 -0700)]
Merge "fix typo in LayerBase::dump()" into jb-mr1-dev

11 years agofix typo in LayerBase::dump()
Mathias Agopian [Wed, 12 Sep 2012 03:52:46 +0000 (20:52 -0700)]
fix typo in LayerBase::dump()

Change-Id: Ie4861a58baed003b7ef643931d41f6be3fbfd00c

11 years agoReduce failure uncertainty
Andy McFadden [Tue, 11 Sep 2012 22:15:13 +0000 (15:15 -0700)]
Reduce failure uncertainty

This adds a trivial workaround for a one-shot boot time crash, plus
an explicit check and abort for a failure condition that currently
presents as a less obvious failure.

Bug: 71455217147557
Change-Id: I548f6a9caa9f0bd5710aaecea0e1c6c7c8f2f281

11 years agoReshuffle FramebufferSurface
Andy McFadden [Mon, 10 Sep 2012 21:08:09 +0000 (14:08 -0700)]
Reshuffle FramebufferSurface

FramebufferSurface no longer speaks directly to the FB HAL.  Now
everything goes through HWComposer (which may or may not be
connected to a hardware composer).

Added display index arg to some query methods.

Change-Id: Id3e157d2d4e3555d33afbb703e518b6e92e2d6d5

11 years agoAdd stack dump from drmserver process to bugreports
James Dong [Mon, 10 Sep 2012 23:08:48 +0000 (16:08 -0700)]
Add stack dump from drmserver process to bugreports

This would be helpful tracking down ANR issues in drmserver

o related-to-bug: 7132419

Change-Id: I7eceaa0c29af26bd0092110be6bddf8f4c063545

11 years agoSurfaceTexture: eglDestroySync after duping its fd
Jamie Gennis [Mon, 10 Sep 2012 21:49:42 +0000 (14:49 -0700)]
SurfaceTexture: eglDestroySync after duping its fd

This change adds a call to eglDestroySync after we've dup'd the fd for the
Android fence that the EGLSyncKHR object wraps.

Change-Id: I4fa6ece863260793630d70bb9a69d6284d05d99e

11 years agoSurfaceTexture: use eglWaitSync
Jamie Gennis [Mon, 10 Sep 2012 00:48:42 +0000 (17:48 -0700)]
SurfaceTexture: use eglWaitSync

This change adds a compile-option to use eglWaitSyncANDROID to ensure that
texturing operations that access the current buffer of a SurfaceTexture do not
occur until the buffer is completely written.  It also moves this
synchronization into a new SurfaceTexture method called doGLFenceWait and
changes SurfaceFlinger's Layer class to use that method rather than performing
its own wait on the fence.

Change-Id: I70afa88086ca7ff49a80e3cd03d423767db7cb88

11 years agoEGL: Add the EGL_ANDROID_wait_sync extension
Jamie Gennis [Mon, 10 Sep 2012 00:46:17 +0000 (17:46 -0700)]
EGL: Add the EGL_ANDROID_wait_sync extension

Change-Id: Ie9a78e07fcaf27c5c13797141ad3c692217607fb

11 years agoMerge "SurfaceTexture: use EGL-created native fences" into jb-mr1-dev
Jamie Gennis [Sun, 9 Sep 2012 20:00:16 +0000 (13:00 -0700)]
Merge "SurfaceTexture: use EGL-created native fences" into jb-mr1-dev

11 years agoSurfaceTexture: use EGL-created native fences
Jamie Gennis [Thu, 6 Sep 2012 21:54:19 +0000 (14:54 -0700)]
SurfaceTexture: use EGL-created native fences

This change adds support for using Android fences that come from EGLSyncKHR
objects as the release fence for a buffer.

Change-Id: Ice192ce2ec001020f909a2018afdf0f17b24dec9

11 years agoEnsure that viewport and frame are initialized.
Jeff Brown [Sun, 9 Sep 2012 07:07:17 +0000 (00:07 -0700)]
Ensure that viewport and frame are initialized.

onInitializeDisplays() was posting a transaction with changes
to the display projection.  Unfortunately, it only set the
display orientation field and left viewport and frame
uninitialized.

The uninitialized values flowed downstream and found themselves
baked into a bogus DisplayDevice mGlobalTransform.  That transform
was then applied to some Rects which were turned into Regions
that were them combined with other Regions.

Under certain situations, the uninitialized data might have
a largish value, resulting in the creation of Regions with
components in excess of the Region max-value limit of 0x7ffffff
(note that this is not INT_MAX).  Later when performing a
binary operation using the Region, the Spanner would loop
indefinitely trying to figure out how to stuff a humongous
region inside of a max-value region.  Not content to try
just once, the Spanner would continue trying again and
again, pegging the CPU and hanging surface flinger during boot.

Insanity soon followed.

Bug: 7130713
Change-Id: I0016f0c9662185be833474c212a1dd408096ae23

11 years agoFix display projection.
Jeff Brown [Fri, 7 Sep 2012 19:55:10 +0000 (12:55 -0700)]
Fix display projection.

Change-Id: I0f253dc3759b99e05ff8344b0f513d8c289702e7