Commit Graph

1491 Commits

Author SHA1 Message Date
Michael Wright 6f783602c0 Move inputflinger process to host directory
Change-Id: I08ee44bf8b93e7f1760ee9f8d9876a1e2e2e86c8
2015-02-23 16:04:57 -08:00
Dan Stoza 3890c83721 am 40b4e23a: Merge "resolved conflicts for merge of 1665c8e1 to lmp-mr1-dev-plus-aosp" into lmp-mr1-dev-plus-aosp
* commit '40b4e23a0396614c841977e932218e3f53089a4a':
  Revert "SurfaceFlinger: Attempt to attribute fds to layers"
2015-01-27 23:42:56 +00:00
Yabin Cui 3d6c569140 am 39d890d9: am 6e32c037: Merge "Kill HAVE_PTHREADS."
* commit '39d890d9aed5cb07b8a166a749299b9d24d8f137':
  Kill HAVE_PTHREADS.
2015-01-27 23:42:55 +00:00
Dan Stoza 40b4e23a03 Merge "resolved conflicts for merge of 1665c8e1 to lmp-mr1-dev-plus-aosp" into lmp-mr1-dev-plus-aosp 2015-01-27 20:06:34 +00:00
Yabin Cui 39d890d9ae am 6e32c037: Merge "Kill HAVE_PTHREADS."
* commit '6e32c0377db89bafa477715b3a02431d651978cf':
  Kill HAVE_PTHREADS.
2015-01-27 19:56:06 +00:00
Dan Stoza 22d0bdf326 resolved conflicts for merge of 1665c8e1 to lmp-mr1-dev-plus-aosp
Change-Id: I0be2ecb8085f2cd9560138460bcc27d71c011608
2015-01-27 11:49:26 -08:00
Dan Stoza 1665c8e101 Revert "SurfaceFlinger: Attempt to attribute fds to layers"
This reverts commit 03eccb6616.

Change-Id: I4f0da7bb62bf77bb3d399aee601beae5e03928fe
2015-01-27 11:03:50 -08:00
Yabin Cui 8fb2d25ff3 Kill HAVE_PTHREADS.
Bug: 19083585
Change-Id: I355491de945590f43c82bdcb7968b01b4bff6e06
2015-01-26 22:36:36 -08:00
Dan Stoza b62767e855 am a5cbb1f1: am ef1c17ae: SurfaceFlinger: Make log message 64-bit compatible
* commit 'a5cbb1f18b6eb4e0db27d98bea0731393b7438d1':
  SurfaceFlinger: Make log message 64-bit compatible
2015-01-17 00:53:36 +00:00
Dan Stoza 3c7eb4fe23 am 3372cc25: resolved conflicts for merge of 03eccb66 to lmp-mr1-dev-plus-aosp
* commit '3372cc25df255b94e4eb75920afaf43ee5edc39f':
  SurfaceFlinger: Attempt to attribute fds to layers
2015-01-17 00:53:35 +00:00
Dan Stoza a5cbb1f18b am ef1c17ae: SurfaceFlinger: Make log message 64-bit compatible
* commit 'ef1c17ae9417abc1e21e49dbc629e448efc947dc':
  SurfaceFlinger: Make log message 64-bit compatible
2015-01-17 00:50:53 +00:00
Dan Stoza 3372cc25df resolved conflicts for merge of 03eccb66 to lmp-mr1-dev-plus-aosp
Change-Id: I1f38cbe7019b2b48b1094dee154ad97c23fd22c2
2015-01-16 16:18:51 -08:00
Dan Stoza ef1c17ae94 SurfaceFlinger: Make log message 64-bit compatible
Fixes the build on 64-bit targets that complain about using a size_t
with a %d in a format string

Change-Id: I7dfcd3a49eb0dbc5dffeb82bb7208de7f7925f08
2015-01-16 15:58:13 -08:00
Dan Stoza 03eccb6616 SurfaceFlinger: Attempt to attribute fds to layers
This tracks fds when layers are created and destroyed in an effort to
determine which specific app (if any) is active when fds are leaked

Bug: 19017008
Change-Id: I1f1d5a9cbc1399e3df3a2d350324f80b3a4e3477
2015-01-16 15:02:22 -08:00
Jesse Hall 8eb8069a2d am 9c22ac77: am 5b730570: Merge "surfaceflinger: use Mutex timedLock instead of tryLock loop"
* commit '9c22ac77e41b8bbddbb64959acabce3f3a07345d':
  surfaceflinger: use Mutex timedLock instead of tryLock loop
2015-01-13 20:32:28 +00:00
Jesse Hall 9c22ac77e4 am 5b730570: Merge "surfaceflinger: use Mutex timedLock instead of tryLock loop"
* commit '5b730570be2bd1f90346a5921d0b70dc11351396':
  surfaceflinger: use Mutex timedLock instead of tryLock loop
2015-01-12 23:41:46 +00:00
Jesse Hall 5b730570be Merge "surfaceflinger: use Mutex timedLock instead of tryLock loop" 2015-01-12 23:33:07 +00:00
Jesse Hall fcd15b478c surfaceflinger: use Mutex timedLock instead of tryLock loop
Rather than trying to acquire the state lock without waiting three
times at 1 second intervals in SurfaceFlinger::dump(), just try to
acquire the lock once with a 1 second timeout. Avoids spurious mutex
acquire failures that lead to flaky
com.android.cts.jank.opengl.CtsHostJankOpenGl results.

Bug: 18842510
Change-Id: I00ce6109647de2aef8831dd2f8fa98652ba7f4e0
2015-01-10 15:41:01 -08:00
Elliott Hughes e0e29de5c1 am 23958e14: am a7dcab69: Merge "We have POSIX clocks, and we don\'t need to ask for the openssl headers."
* commit '23958e1436565b333ce7f3022bc52a10d4732ef6':
  We have POSIX clocks, and we don't need to ask for the openssl headers.
2015-01-10 00:18:15 +00:00
Elliott Hughes 23958e1436 am a7dcab69: Merge "We have POSIX clocks, and we don\'t need to ask for the openssl headers."
* commit 'a7dcab6954467fa3726824a099b83d0e7490d6d5':
  We have POSIX clocks, and we don't need to ask for the openssl headers.
2015-01-10 00:14:12 +00:00
Elliott Hughes 5ea47f7a32 We have POSIX clocks, and we don't need to ask for the openssl headers.
This code doesn't need to run on the Mac, and the BoringSSL transition
will be easier without references to external/openssl.

Change-Id: I14ea11fa2911af0f4e95e69636e6a2c26126cbe0
2015-01-09 15:56:15 -08:00
Narayan Kamath a3ef067c00 am 106547c1: am 033f7e8e: Merge "InputDispatcher: Optimize count()"
* commit '106547c1e33453b7e20b7b387087092d36aa6a72':
  InputDispatcher: Optimize count()
2014-12-24 10:37:38 +00:00
Narayan Kamath 106547c1e3 am 033f7e8e: Merge "InputDispatcher: Optimize count()"
* commit '033f7e8e35ac76404fe823a67e07ba7c42bc357c':
  InputDispatcher: Optimize count()
2014-12-24 10:32:20 +00:00
Narayan Kamath 033f7e8e35 Merge "InputDispatcher: Optimize count()" 2014-12-24 10:25:43 +00:00
Dmitriy Ivanov e9b6f1f7bb Switch to libsigchain.a
Use LOCAL_WHOLE_STATIC_LIBRARIES to instruct static linker
  to export symbols from the static library.

(cherry picked from commit 4340a14fbf)

Bug: 18701723
Change-Id: I70f6fdb64b0d1adbadf96c8de85870a903ec186a
2014-12-10 10:28:50 -08:00
Dan Stoza dd883c0b08 libgui: Enable -Weverything and -Werror
Enables -Weverything and -Werror, with just a few exceptions for
warnings we can't (or shouldn't need to) work around.

This is a squashed commit based on an initial change with a couple of
fixes to avoid breaking certain targets. The source commits are:
  d723bd7669
  00d504c06e
  429ba89cd2

Change-Id: I034abec27bf4020d84af60d7acc1939c59986dd6
2014-12-05 14:59:29 -08:00
Dan Stoza d723bd7669 libgui: Enable -Weverything and -Werror
Enables -Weverything and -Werror, with just a few exceptions for
warnings we can't (or shouldn't need to) work around.

Change-Id: I034abec27bf4020d84af60d7acc1939c59986dd6
2014-12-05 11:06:44 -08:00
Dan Albert 7530114619 am 5588d900: Merge "Enable clang for libui/libgui/surfaceflinger"
* commit '5588d9000cd1ef217185c9001d6b5ecd84db9741':
  Enable clang for libui/libgui/surfaceflinger
2014-12-05 18:01:48 +00:00
Dan Stoza 01049c8321 Enable clang for libui/libgui/surfaceflinger
Enables clang and C++11 for libui/libgui/surfaceflinger, and
eliminates all compile-time warnings.

Change-Id: Ie237fdb5ae44f2bfcddaa884f9c65ec3f08ae50f
(cherry picked from commit f10c46ef85)
2014-12-04 17:56:17 -08:00
Dan Stoza d6739d5e44 am db5827d3: am 5878444f: SurfaceFlinger: Listen to HWC invalidate
* commit 'db5827d314ddca3d473947b4ef49e811fad70069':
  SurfaceFlinger: Listen to HWC invalidate
2014-12-04 16:15:54 +00:00
Dan Stoza db5827d314 am 5878444f: SurfaceFlinger: Listen to HWC invalidate
* commit '5878444fb8da043021f30d3de739531f15390df5':
  SurfaceFlinger: Listen to HWC invalidate
2014-12-03 20:43:29 +00:00
Dan Stoza 5878444fb8 SurfaceFlinger: Listen to HWC invalidate
"Do less work when using PTS" broke the invalidate path up from HWC
to SurfaceFlinger. When HWC would signal an invalidate, SurfaceFinger
would wake up, see no new buffers, and go back to sleep. This is fine,
except when the invalidate is a result of an HDMI hotplug, in which
case the screen remains blank. This change makes that functionality
work again.

Bug: 18564815
Bug: 18558468
Change-Id: I2e2171d86839945f4e4e6555d66f7e2895bd096a
2014-12-02 16:58:17 -08:00
Jon McCaffrey 65dbe971b1 InputDispatcher: Optimize count()
Count items as they are added and removed rather than iterating over the
entire list to count them.

Increases performance slightly, particularly when tracing is turned on,
which causes count to be queried more often, and when the number of
items in the queues grow large.  This can happen due to applications not
responding, for example.

Change-Id: I0f11f7edd46089612af910cdfabfeb3ee685d7d9
2014-11-26 12:04:47 -08:00
Chih-hung Hsieh c4764f9e57 am 7d831769: am 46ca041f: Merge "Don\'t error out because SensorEventConnection::dump overloads BBinder::dump"
* commit '7d831769fce188251afb02e6b933be7bdfe504b4':
  Don't error out because SensorEventConnection::dump overloads BBinder::dump
2014-11-26 00:01:55 +00:00
Chih-hung Hsieh 7d831769fc am 46ca041f: Merge "Don\'t error out because SensorEventConnection::dump overloads BBinder::dump"
* commit '46ca041f43e3d80029782b12c994b232dc01b5d5':
  Don't error out because SensorEventConnection::dump overloads BBinder::dump
2014-11-25 23:55:52 +00:00
Bernhard Rosenkränzer 72952efe5c Don't error out because SensorEventConnection::dump overloads BBinder::dump
clang warns about SensorEventConnection::dump overloading BBinder::dump
in some conditions.

Since the cause isn't fixable without changing the API, tell clang not
to error out on it.

Change-Id: I15659de7c5499d937019599cfefb01305039e6b5
Signed-off-by: Bernhard Rosenkränzer <Bernhard.Rosenkranzer@linaro.org>
2014-11-25 15:42:27 -08:00
chh 5394346ada am 22b99e3a: am 45aa0227: Merge "Fix potential format string vulnerability"
* commit '22b99e3a9a5797deada897102e71e9a88ae46d24':
  Fix potential format string vulnerability
2014-11-25 19:57:17 +00:00
chh 22b99e3a9a am 45aa0227: Merge "Fix potential format string vulnerability"
* commit '45aa022710165c321cdec9a475f269d6932fe1f3':
  Fix potential format string vulnerability
2014-11-25 19:04:12 +00:00
Michael Lentine 347a2acf7e am 1e611662: am b947f29a: Merge "Add clamp to Layer and update Transform inverse." into lmp-mr1-dev
* commit '1e6116621bc2f7aedfd52a5f1327b530328435b0':
  Add clamp to Layer and update Transform inverse.
2014-11-25 18:56:41 +00:00
Michael Lentine 1e6116621b am b947f29a: Merge "Add clamp to Layer and update Transform inverse." into lmp-mr1-dev
* commit 'b947f29a6af1622cda16d0b7112595082750dd07':
  Add clamp to Layer and update Transform inverse.
2014-11-25 18:44:51 +00:00
Bernhard Rosenkränzer 5f6199373d Fix potential format string vulnerability
A sensor name containing a format string could have interesting side
effects...

Change-Id: If7f1378aa68572d9716c339728eab18faa6b9f2a
Signed-off-by: Bernhard Rosenkränzer <Bernhard.Rosenkranzer@linaro.org>
2014-11-24 16:59:39 -08:00
Michael Lentine 28ea217ff4 Add clamp to Layer and update Transform inverse.
Ensure that the adjusted transparent region is within
the display bounds by clamping after the transformation
is applied and clean up transform's inverse function.

Bug: 18452546

Change-Id: Ia473e483ee8374177bcb84d8192eb1f0e86f022a
2014-11-21 17:05:18 -08:00
Dan Albert c1ced8bbcd am c894c204: Merge "C++11 compatibility."
* commit 'c894c2045f589571c80af0648e7a9dcd7e97b6a8':
  C++11 compatibility.
2014-11-20 23:00:48 +00:00
Dan Albert 3bdc5b8268 C++11 compatibility.
* Explicit conversion for atomic_uintptr_t initialization.
 * Fix string literal concatenation to not be a UD literal.
 * Use __typeof__ instead of typeof (should become decltype once this
   actually moves to C++11).

Bug: 18466763
Change-Id: I4eedddfb945a2a703ed27317cb6e2b3041b1ebfc
2014-11-20 21:04:35 +00:00
Dan Stoza e8e23c8b79 am 686c5be4: am 6b9454d1: SurfaceFlinger: Do less work when using PTS
* commit '686c5be4722dce02ae8e5580d6677f1eeea22464':
  SurfaceFlinger: Do less work when using PTS
2014-11-18 20:18:27 +00:00
Dan Stoza 686c5be472 am 6b9454d1: SurfaceFlinger: Do less work when using PTS
* commit '6b9454d1fee0347711af1746642aa7820b1ea04d':
  SurfaceFlinger: Do less work when using PTS
2014-11-18 02:07:36 +00:00
Chih-hung Hsieh ebcc45df77 am accddd9c: am 947a6adf: Merge "Remove comparisons that can\'t be true"
* commit 'accddd9ca0bef572674b895b9b2b0553b133c793':
  Remove comparisons that can't be true
2014-11-18 00:27:52 +00:00
Chih-hung Hsieh accddd9ca0 am 947a6adf: Merge "Remove comparisons that can\'t be true"
* commit '947a6adf97d9ba86e3ef5704d523b4971246ff1e':
  Remove comparisons that can't be true
2014-11-18 00:23:08 +00:00
Dan Stoza 6b9454d1fe SurfaceFlinger: Do less work when using PTS
Currently, SurfaceFlinger is very dumb about how it handles buffer
updates at less than 60fps. If there is a new frame pending, but its
timestamp says not to present it until later SurfaceFlinger will wake
up every vsync until it is time to present it. Even worse, if
SurfaceFlinger has woken up but nothing has changed, it still goes
through the entire composition process.

This change (mostly) fixes that inefficiency. SurfaceFlinger will
still wake up every refresh period while there is a new frame
pending, but if there is no work to do, it will almost immediately go
back to sleep.

Bug: 18111837
Change-Id: I7825bacd37f40bf26edcc6a5e0f051dce45291fb
2014-11-17 21:32:13 +00:00
Bernhard Rosenkränzer 6183eb72ec Remove comparisons that can't be true
keyBitmask and ledBitmask are arrays, "!their address" always evaluates to
false. clang complains about this.

Change-Id: I6aed45a203b0eeaad2093dbdebea03a2c2fc1a3d
Signed-off-by: Bernhard Rosenkränzer <Bernhard.Rosenkranzer@linaro.org>
2014-11-17 21:09:14 +01:00