Commit Graph

1693 Commits

Author SHA1 Message Date
Dan Stoza
49b2e13629 am 6a25a287: am 806334aa: am 1998615f: Merge "sf: Initialize EventThread before creating HWC"
* commit '6a25a2872852f23058268adcec61600460fcdfb6':
  sf: Initialize EventThread before creating HWC
2015-06-30 17:49:47 +00:00
Dan Stoza
6a25a28728 am 806334aa: am 1998615f: Merge "sf: Initialize EventThread before creating HWC"
* commit '806334aacd089d1c419ed77021a2b1bb4f7644ef':
  sf: Initialize EventThread before creating HWC
2015-06-30 17:38:41 +00:00
Michael Wright
2e099b2425 am fd0fdaf7: am 3643c88f: Merge "Send cancelation events to monitors when injection fails." into mnc-dev
* commit 'fd0fdaf73b1e8fbf643152f532f500be70f11a26':
  Send cancelation events to monitors when injection fails.
2015-06-29 17:47:15 +00:00
Michael Wright
fd0fdaf73b am 3643c88f: Merge "Send cancelation events to monitors when injection fails." into mnc-dev
* commit '3643c88f7b557e241d65c4857eaf49e28e7c03a2':
  Send cancelation events to monitors when injection fails.
2015-06-29 17:40:25 +00:00
Michael Wright
3643c88f7b Merge "Send cancelation events to monitors when injection fails." into mnc-dev 2015-06-29 17:10:46 +00:00
Dan Stoza
c08e7cb7b1 am 488986f4: am f413de05: Merge "libgui: Fix handling of rotated surface damage" into mnc-dev
* commit '488986f4ad7a92b04fdfd761ae07785019d2a9d3':
  libgui: Fix handling of rotated surface damage
2015-06-26 20:15:24 +00:00
Dan Stoza
488986f4ad am f413de05: Merge "libgui: Fix handling of rotated surface damage" into mnc-dev
* commit 'f413de05cfb9a1b84b73c8e6c306d4142130c5f7':
  libgui: Fix handling of rotated surface damage
2015-06-26 20:01:09 +00:00
Dan Stoza
db4850c01f libgui: Fix handling of rotated surface damage
Incoming surface damage was not aware that the EGL implementation was
rotating buffers in response to SurfaceFlinger's transform hint. This
didn't affect all cases because the effect was to apply a 90 degree
rotation instead of a 270 degree rotation. For full-screen updates,
things more or less worked, but in other cases this caused corruption.

This fixes that by correctly undoing the effect of rotated buffers on
the incoming surface damage, and then passing that damage down
untouched to HWC.

Bug: 22068334
Change-Id: I226ecfc7a91fe2e16edd2aa6d9149f0d26b529d6
2015-06-25 16:10:18 -07:00
Aravind Akella
12b26278df am e6045537: am 7a1b5d5d: Merge "Fix crash in SensorService. Ignore devices with no sensors." into mnc-dev
* commit 'e6045537bbce4c4f98e6a1149187bbcdaff57bcd':
  Fix crash in SensorService. Ignore devices with no sensors.
2015-06-24 16:08:13 +00:00
Aravind Akella
e6045537bb am 7a1b5d5d: Merge "Fix crash in SensorService. Ignore devices with no sensors." into mnc-dev
* commit '7a1b5d5dec10f05ec29e7251ada440b47a34c6aa':
  Fix crash in SensorService. Ignore devices with no sensors.
2015-06-24 15:56:29 +00:00
Aravind Akella
7a1b5d5dec Merge "Fix crash in SensorService. Ignore devices with no sensors." into mnc-dev 2015-06-24 15:34:59 +00:00
Aravind Akella
ee155cadb2 Fix crash in SensorService. Ignore devices with no sensors.
Change-Id: I1491740baa6348f97c336b6883b11ad2ab93cf73
2015-06-24 08:32:56 -07:00
Dan Stoza
e2bfdfafae am c8c0992a: am 0638a4fa: Merge "libgui/SF: Propagate SECURE Layer flag changes" into mnc-dev
* commit 'c8c0992ace7733c983e87e8e7154d844a54e5741':
  libgui/SF: Propagate SECURE Layer flag changes
2015-06-23 18:13:16 +00:00
Michael Wright
39c32ecf37 am 7d3ad695: Merge commit \'71997c1a\' into manualmerge
* commit '7d3ad695304a1f24026227e630add6edd76fd0d6':
  Add new AINPUT_SOURCE_BLUETOOTH_STYLUS
2015-06-23 18:13:15 +00:00
Dan Stoza
c8c0992ace am 0638a4fa: Merge "libgui/SF: Propagate SECURE Layer flag changes" into mnc-dev
* commit '0638a4fac7250e260c0102c770090cb7eefca936':
  libgui/SF: Propagate SECURE Layer flag changes
2015-06-23 18:07:31 +00:00
Michael Wright
7d3ad69530 Merge commit '71997c1a' into manualmerge
Change-Id: Ia68fbd20ce66571dfd33764e52c3a00e2285e648
2015-06-23 19:04:31 +01:00
Dan Stoza
0638a4fac7 Merge "libgui/SF: Propagate SECURE Layer flag changes" into mnc-dev 2015-06-23 15:44:10 +00:00
Michael Wright
71997c1a92 Merge "Add new AINPUT_SOURCE_BLUETOOTH_STYLUS" into mnc-dev 2015-06-23 12:49:30 +00:00
Aravind Akella
645832b969 am 357e7d7d: am 94188464: Merge "More information in sensor bugreports." into mnc-dev
* commit '357e7d7dcdd579d979054daf0a28b0a348d7ee7a':
  More information in sensor bugreports.
2015-06-22 18:53:32 +00:00
Aravind Akella
357e7d7dcd am 94188464: Merge "More information in sensor bugreports." into mnc-dev
* commit '9418846431f494b53a5e9c617aed27693079c163':
  More information in sensor bugreports.
2015-06-22 18:40:18 +00:00
Dan Stoza
2311608667 libgui/SF: Propagate SECURE Layer flag changes
This allows changes to the SECURE flag to propagate down to
Layers in SurfaceFlinger so that WindowManager can change it on the fly
in response to device policy updates.

Bug: 20934462
Change-Id: I558f6d22c6273be373f1f480365e42536af18a33
2015-06-18 15:11:20 -07:00
Aravind Akella
18d6d51a00 More information in sensor bugreports.
i) Log last 20 activations/deactivations of sensors.
ii) Increase logging upto 50 events for accelerometer, step_counter and significant motion.

Change-Id: I3966ed0abda8b705f3d16e94a9370fa1b97baa57
2015-06-18 14:24:05 -07:00
Saurabh Shah
f948105810 sf: Initialize EventThread before creating HWC
Once HWC is created, it could use any of the provided hooks, which
could lead to a crash if the EventThread (handler) isn't initialized
prior to creating HWC.

Change-Id: I5ea35fe9bcb150fb74aae1295b798bd787ad6cee
2015-06-17 11:08:29 -07:00
Manoj Kumar AVM
f1bc814276 am 407f48c8: am e04e4edc: sf: Fix incorrect state reporting in dumpsys
* commit '407f48c825351e7b5cbf455a85aff2154c696fdd':
  sf: Fix incorrect state reporting in dumpsys
2015-06-12 17:44:06 +00:00
Manoj Kumar AVM
407f48c825 am e04e4edc: sf: Fix incorrect state reporting in dumpsys
* commit 'e04e4edcd1a852058775caa34cf73e2c20dc1066':
  sf: Fix incorrect state reporting in dumpsys
2015-06-12 17:31:23 +00:00
Manoj Kumar AVM
e04e4edcd1 sf: Fix incorrect state reporting in dumpsys
Dumpsys utility accesses layer compositionType variable
with out proper protection. These variables are modified
during hwc_prepare call. Existing HAL lock protection is not
sufficient to address this issue. Failure to do this will
result in incorrect state reporting in dumpsys.

A new displayLock mutex in HWComposer will be used in both
dumpsys and draw calls to ensure correct state is accessed.

Change-Id: I8a57de59525adc0e089b3bed95c067c01e42b666
(cherry picked from commit e54506b81a)
2015-06-12 09:48:07 -07:00
Michael Wright
2f78b68cf1 Add new AINPUT_SOURCE_BLUETOOTH_STYLUS
Bug: 21531826
Change-Id: I3792860ad3f6579ceb50ccaa212f8fbd471a9b6b
2015-06-12 15:25:08 +01:00
Michael Wright
fa13dcf39f Send cancelation events to monitors when injection fails.
Bug: 20649729
Change-Id: I46cd14ac1f040d404c0b1581b38fa07a944e5fb9
2015-06-12 13:25:11 +01:00
Manoj Kumar AVM
e54506b81a sf: Fix incorrect state reporting in dumpsys
Dumpsys utility accesses layer compositionType variable
with out proper protection. These variables are modified
during hwc_prepare call. Existing HAL lock protection is not
sufficient to address this issue. Failure to do this will
result in incorrect state reporting in dumpsys.

A new displayLock mutex in HWComposer will be used in both
dumpsys and draw calls to ensure correct state is accessed.

Change-Id: I8a57de59525adc0e089b3bed95c067c01e42b666
2015-06-11 18:21:18 -04:00
Tatenda Chipeperekwa
40da48bfdf sf: Add a NULL check in getDisplayConfigs
Validate the display binder by adding a NULL check in getDisplayConfigs.
This will prevent a false match if the caller queries the display
configs for an inactive display (whose binder is NULL by default).

Without this change we might end up attempting to index the display
config array, which is unpopulated for inactive displays, and this will
result in a crash. (See getDisplayInfo in SurfaceComposerClient.cpp for
an example of this scenario)

Change-Id: Ib32a7dc8378d3438df0dba1ecd608bbcfc837717
2015-06-11 12:28:41 -07:00
Tatenda Chipeperekwa
0abd853a68 am c1d4662f: am 23e16bb5: sf: Add a NULL check in getDisplayConfigs
* commit 'c1d4662f0e596021e0d8360cd1c5d213c3c8c4ba':
  sf: Add a NULL check in getDisplayConfigs
2015-06-11 19:09:30 +00:00
Tatenda Chipeperekwa
c1d4662f0e am 23e16bb5: sf: Add a NULL check in getDisplayConfigs
* commit '23e16bb5dae277cd20a739ca56553ae931c43ccf':
  sf: Add a NULL check in getDisplayConfigs
2015-06-11 18:57:28 +00:00
Tatenda Chipeperekwa
23e16bb5da sf: Add a NULL check in getDisplayConfigs
Validate the display binder by adding a NULL check in getDisplayConfigs.
This will prevent a false match if the caller queries the display
configs for an inactive display (whose binder is NULL by default).

Without this change we might end up attempting to index the display
config array, which is unpopulated for inactive displays, and this will
result in a crash. (See getDisplayInfo in SurfaceComposerClient.cpp for
an example of this scenario)

Change-Id: I1a12f43b7c375b9c01998dadd5b658275c733fb2
(cherry picked from commit ac71c26e9180d9d181be5ec9e45da72d39144a8b)
2015-06-11 10:40:21 -07:00
Aravind Akella
cd2e238ead am ce5af4b2: am 52720f45: Merge "Use LOCATION_HARDWARE permission for data injection." into mnc-dev
* commit 'ce5af4b234ed6f5d6c39d47426d4e961bf3c2858':
  Use LOCATION_HARDWARE permission for data injection.
2015-06-11 02:35:26 +00:00
Aravind Akella
ce5af4b234 am 52720f45: Merge "Use LOCATION_HARDWARE permission for data injection." into mnc-dev
* commit '52720f45098e9aed57c906e64a13e4a4a2173ce8':
  Use LOCATION_HARDWARE permission for data injection.
2015-06-11 02:08:19 +00:00
Aravind Akella
52720f4509 Merge "Use LOCATION_HARDWARE permission for data injection." into mnc-dev 2015-06-10 22:56:27 +00:00
Aravind Akella
a8814ce478 Use LOCATION_HARDWARE permission for data injection.
Change-Id: Ie81cb0d5f537d5431f2127891cca1d39c969ee7b
2015-06-10 15:15:57 -07:00
Dan Stoza
d1adebc2da am 355950c1: am d177e044: Merge "SF: Swap w/h when capturing rotated screenshots" into mnc-dev
* commit '355950c1fc19c35c75203ea761882168f0980181':
  SF: Swap w/h when capturing rotated screenshots
2015-06-10 18:08:31 +00:00
Dan Stoza
355950c1fc am d177e044: Merge "SF: Swap w/h when capturing rotated screenshots" into mnc-dev
* commit 'd177e044d129bbecc3900a7fcd442b354de768df':
  SF: Swap w/h when capturing rotated screenshots
2015-06-10 17:52:50 +00:00
Michael Wright
a393c62f22 am f8b34319: am 043bd36b: Merge "Only log dropped input when disabled for the first event." into mnc-dev
* commit 'f8b34319a4c1ccce63b5a8e4732f162d228085cb':
  Only log dropped input when disabled for the first event.
2015-06-10 17:47:58 +00:00
Dan Stoza
65dc7eeff0 SF: Swap w/h when capturing rotated screenshots
Swaps width and height when capturing a screenshot that is rotated by
90 or 270 degrees.

Bug: 8433742
Change-Id: Ibf0b604f541e3cc271e56fe0ad04dc366beb5d79
(cherry picked from commit 3502416204)
2015-06-10 10:33:21 -07:00
Michael Wright
f8b34319a4 am 043bd36b: Merge "Only log dropped input when disabled for the first event." into mnc-dev
* commit '043bd36b0d50efa81d010c64009317af160d5fec':
  Only log dropped input when disabled for the first event.
2015-06-10 17:32:41 +00:00
Dan Stoza
d177e044d1 Merge "SF: Swap w/h when capturing rotated screenshots" into mnc-dev 2015-06-10 17:28:33 +00:00
Michael Wright
043bd36b0d Merge "Only log dropped input when disabled for the first event." into mnc-dev 2015-06-10 17:08:03 +00:00
Tim Kilbourn
82cdd76e60 Merge "Mock out more inputflinger host functions" 2015-06-10 16:38:42 +00:00
Michael Wright
3a98172289 Only log dropped input when disabled for the first event.
Bug: 19851495
Change-Id: I8cb8076723c1ca1732c3bc37f283d8eb48b7bee0
2015-06-10 15:26:13 +01:00
Dan Stoza
3502416204 SF: Swap w/h when capturing rotated screenshots
Swaps width and height when capturing a screenshot that is rotated by
90 or 270 degrees.

Bug: 8433742
Change-Id: Ibf0b604f541e3cc271e56fe0ad04dc366beb5d79
2015-06-09 16:46:20 -07:00
Dan Stoza
074a13a3cb SF: Don't crop surface damage against viewport
Apply the display transform to surface damage, but don't intersect it
with the viewport.

Bug: 21486007
Change-Id: I94e697cea52096a960385d5f3b89609fdcf30a02
(cherry picked from commit 17833a1b0d)
2015-06-09 13:27:45 -07:00
Dan Stoza
53a2e97a78 libgui/SurfaceFlinger: Add getConsumerName
Adds a getConsumerName method to IGraphicBufferProducer and Surface.
Currently, the name is cached inside of IGBP and is update on connect
and dequeueBuffer, which should be good enough for most uses.

Bug: 6667401
Change-Id: I22c7881d778e495cf8276de7bbcd769e52429915
(cherry picked from commit c6f30bdee1)
2015-06-09 11:28:37 -07:00
Tim Kilbourn
c472986d4c Mock out more inputflinger host functions
Change-Id: I3de1e95930578410d8f7c1e77329c00f05b72325
2015-06-08 14:44:33 -07:00