OSDN Git Service

android-x86/frameworks-av.git
7 years agoRetry allocations in case of ENODEV
Jerry Zhang [Fri, 3 Feb 2017 02:14:33 +0000 (18:14 -0800)]
Retry allocations in case of ENODEV

Unlike the read() and write() calls, the ioctl() call
does not wait for endpoints to be enabled, which is
problematic if ioctls() are the first calls on the
usb connection, since they may be called before the
endpoints are set up. We'll have to retry if this
causes them to fail.

Bug: 34822471
Test: Change configs to mtp and ptp
Change-Id: I89610b9614c33f0b22535cc68cd0c9b502cb55c9

7 years agoFix GetPartialObject on FFS
Jerry Zhang [Sat, 4 Feb 2017 00:31:31 +0000 (16:31 -0800)]
Fix GetPartialObject on FFS

Linux apps use GetPartialObject to access
MTP files directly. Fix file offset handling
as well as lengths shorter than packet size.

Bug: 34822471
Test: Attach photos in Gmail, open directly from device
Change-Id: I9986cd8c70ed261f07e8f96a72e53b87341dd93f

7 years agoMerge "Make Mtp FFS allocations per session rather than per file"
Treehugger Robot [Thu, 2 Feb 2017 23:04:38 +0000 (23:04 +0000)]
Merge "Make Mtp FFS allocations per session rather than per file"

7 years agoMake Mtp FFS allocations per session rather than per file
Jerry Zhang [Fri, 27 Jan 2017 18:29:59 +0000 (10:29 -0800)]
Make Mtp FFS allocations per session rather than per file

Workloads that send a large number of small files could
repeatedly allocate and free the buffer, causing fragmentation
and eventually running out of allocable memory. Instead
have the allocation be once per MTP session, and retry
with smaller buffers if it fails initially.

Bug: 34741015
Bug: 34822471
Test: Transfer files via MTP
Change-Id: I775376076d3a0c26765b211100830ea0c08450ef

7 years agoMerge "Use the new radio_metadata wrapper for safer memory management."
Tomasz Wasilczyk [Fri, 27 Jan 2017 20:26:06 +0000 (20:26 +0000)]
Merge "Use the new radio_metadata wrapper for safer memory management."

7 years agoUse the new radio_metadata wrapper for safer memory management.
Tomasz Wasilczyk [Mon, 23 Jan 2017 22:36:15 +0000 (14:36 -0800)]
Use the new radio_metadata wrapper for safer memory management.

Bug: b/34054813
Test: VTS, manual - both done in internal branch
Change-Id: I3ffb246af9a092d19a4f698d89ed0c03daa04431

7 years agoMerge "Revert "Fix "Dereference of null pointer" compiler warning.""
George Burgess IV [Thu, 26 Jan 2017 20:56:25 +0000 (20:56 +0000)]
Merge "Revert "Fix "Dereference of null pointer" compiler warning.""

7 years agoRevert "Fix "Dereference of null pointer" compiler warning."
Andrii Kulian [Thu, 26 Jan 2017 20:48:44 +0000 (20:48 +0000)]
Revert "Fix "Dereference of null pointer" compiler warning."

This reverts commit 5bfdce99499ef19f7b74471b8b143c4c04d2d947.

Change-Id: I653a233f32ec80022bb8a6f1418e9b74f46ca131

7 years agoMerge "Fix "Dereference of null pointer" compiler warning."
Treehugger Robot [Thu, 26 Jan 2017 20:15:49 +0000 (20:15 +0000)]
Merge "Fix "Dereference of null pointer" compiler warning."

7 years agoFix "Dereference of null pointer" compiler warning.
Caroline Tice [Wed, 7 Dec 2016 04:38:32 +0000 (20:38 -0800)]
Fix "Dereference of null pointer" compiler warning.

This CL fixes the warning:
"frameworks/av/media/libstagefright/codecs/aacenc/src/dyn_bits.c:197:35
warning: Array access (from variable 'sideInfoTab') resutls in a null
pointer dereference"

There's a switch statement that initializes 'sideInfoTab', and it does
not have a default case.   The listed cases seem to cover all the valid
types for the switch variable, but since the declared type is basically
'int', it's possible for it to contain some value not covered by the
other cases, hit the non-existant default case, which leaves sideInfoTab
with its initial NULL value, later being dereferenced.  This CL fixes
this by adding a default case to the switch statement that complains if
it gets an invalid value.

Bug: None
Test: Compiles without the warning.
Change-Id: I1581b3337b6331a694774da27072dd39992e6218

7 years agoMerge "Keep ScopedEndpointBufferAlloc in variables"
Jerry Zhang [Thu, 19 Jan 2017 19:24:05 +0000 (19:24 +0000)]
Merge "Keep ScopedEndpointBufferAlloc in variables"

7 years agoKeep ScopedEndpointBufferAlloc in variables
Jerry Zhang [Wed, 18 Jan 2017 20:03:56 +0000 (12:03 -0800)]
Keep ScopedEndpointBufferAlloc in variables

This way they don't immediately destruct. Also
up the logging for an allocation failure and use
posix_madvise to possibly improve memory performance.

Test: Transfer files and verify that allocs are scoped properly
Bug: 30976142
Change-Id: If8d2c03cefcc98a83bbb57618c35337529437f73

7 years agoMerge "Re-add MTP interface string"
Jerry Zhang [Tue, 17 Jan 2017 22:37:09 +0000 (22:37 +0000)]
Merge "Re-add MTP interface string"

7 years agoRe-add MTP interface string
Jerry Zhang [Wed, 11 Jan 2017 23:17:53 +0000 (15:17 -0800)]
Re-add MTP interface string

The string is used in some hosts like Mac to
check for MTP devices.

Test: Connect device
Bug: 30976142
Change-Id: Iac616997dc8afd0bdf03de0d13dee7baa6483904

7 years agoMerge "liblog: use log/log.h for ALOG macros"
Mark Salyzyn [Thu, 12 Jan 2017 23:44:49 +0000 (23:44 +0000)]
Merge "liblog: use log/log.h for ALOG macros"

7 years agoMerge "Fix issues crashing with Fatal signal when calling getFormat"
Treehugger Robot [Thu, 12 Jan 2017 23:31:55 +0000 (23:31 +0000)]
Merge "Fix issues crashing with Fatal signal when calling getFormat"

7 years agoliblog: use log/log.h for ALOG macros
Mark Salyzyn [Thu, 12 Jan 2017 23:10:27 +0000 (15:10 -0800)]
liblog: use log/log.h for ALOG macros

Test: compile
Bug: 34250038
Change-Id: Ie3b92790df631dbacdd51053264dddeba66913c1

7 years agoMerge "Add missing nullptr checks for data.readCString() strings"
Treehugger Robot [Wed, 11 Jan 2017 19:04:30 +0000 (19:04 +0000)]
Merge "Add missing nullptr checks for data.readCString() strings"

7 years agoFix issues crashing with Fatal signal when calling getFormat
qinzhichao [Sat, 31 Dec 2016 07:36:18 +0000 (15:36 +0800)]
Fix issues crashing with Fatal signal when calling getFormat

when playing multimedia file, GenericSource::getTrackInfo run in the
NuPlayerDriver thread, and GenericSource::getFormatMeta run in the
Generic thread. they would access the critical resource which is
mMetaData in IMediaSource. There is no lock to protect mMetaData.
Occasionally, SIGSEGV occurs when mMetaData point to a new object.

Instead getting trackInfo in Generic thread.

Bug: 34220591
Signed-off-by: qinzhichao <qinzhichao@xiaomi.com>
7 years agoAdd missing nullptr checks for data.readCString() strings
Pavlin Radoslavov [Tue, 10 Jan 2017 07:27:29 +0000 (23:27 -0800)]
Add missing nullptr checks for data.readCString() strings

Protect the Audio Policy Manager by adding extra checks
for data.readCString() strings when parsing / decoding
a Binder transaction.

Also:
 * Moved audio_is_output_device() / audio_is_input_device() checks
   inside handleDeviceConfigChange()
   from the AudioPolicyInterface to the AudioPolicyManager
 * Removed similar redundant checks inside
    AudioPolicyService::setDeviceConnectionState()

Test: code compilation
Change-Id: Ib32a28ba2669b73aaf32b31bb18f41c8dd7d2605

7 years agoMerge "Use FUNCTIONFS_ENDPOINT_ALLOC_BUFFER ioctl to improve performance."
Jerry Zhang [Wed, 11 Jan 2017 00:50:02 +0000 (00:50 +0000)]
Merge "Use FUNCTIONFS_ENDPOINT_ALLOC_BUFFER ioctl to improve performance."

7 years agoUse FUNCTIONFS_ENDPOINT_ALLOC_BUFFER ioctl to improve performance.
Jerry Zhang [Fri, 16 Dec 2016 01:07:38 +0000 (17:07 -0800)]
Use FUNCTIONFS_ENDPOINT_ALLOC_BUFFER ioctl to improve performance.

The ioctl preallocates kernel buffers for the read/write syscalls,
reducing memory fragmentation and allowing for larger buffers,
as well as removing the kmalloc overhead.

Test: Manual
Change-Id: I9f5fef1b1625c1a2cda374541d8042f7e0ba78f5

7 years agoMerge "Convert Android.mk in libaudioclient to Android.bp"
Treehugger Robot [Tue, 10 Jan 2017 21:39:37 +0000 (21:39 +0000)]
Merge "Convert Android.mk in libaudioclient to Android.bp"

7 years agoMerge "liblog: use log/log.h for ALOG macros"
Treehugger Robot [Tue, 10 Jan 2017 21:06:23 +0000 (21:06 +0000)]
Merge "liblog: use log/log.h for ALOG macros"

7 years agoConvert Android.mk in libaudioclient to Android.bp
Jack He [Thu, 8 Dec 2016 23:44:14 +0000 (15:44 -0800)]
Convert Android.mk in libaudioclient to Android.bp

* Since system/bt depends on this library, it needs to be converted to
  Android.bp before the conversion in system/bt can be continued.
* Majority of work is done by androidmk Android.mk > Android.bp
* Fixed sanitize arguements
* Removed LOCAL_EXPORT_C_INCLUDE_DIRS as Android.bp only supports
  exporting sub-directories of current Android.bp file
* Removed frameworks/av/media/libmedia/aidl include path as it no longer
  exists and Android.mk failed to check that
* Removed include path for audio-utils as it is being automatically
  included when we link against libaudioutils
* Android.mk file must be deleted as a library of the same name can only
  be defined once in either Android.bp or Android.mk
* A library defined in Android.bp can be used by either Android.bp or
  Android.mk files. However, a library defined in Android.mk cannot be
  used by Android.bp file. Therefore, for system/bt to link against this
  library in the Android.bp, this library must be converted first

Bug: 32958753
Test: Code compilation, no user visible effect

Change-Id: I2ae87a1151ed4235122c7774096c2dbff8b1fc62

7 years agoliblog: use log/log.h for ALOG macros
Mark Salyzyn [Tue, 10 Jan 2017 17:08:19 +0000 (09:08 -0800)]
liblog: use log/log.h for ALOG macros

Test: compile
Bug: 30465923
Change-Id: I247151363604714088b6059279702702b4e9f89a

7 years agoMerge "MPEG4Write mdhd duration overflow after recording for 15 hours"
Treehugger Robot [Tue, 10 Jan 2017 03:22:24 +0000 (03:22 +0000)]
Merge "MPEG4Write mdhd duration overflow after recording for 15 hours"

7 years agoMerge "Add SSE optimization of FIR float filter"
Andy Hung [Sat, 7 Jan 2017 03:57:08 +0000 (03:57 +0000)]
Merge "Add SSE optimization of FIR float filter"

7 years agoMerge "Unversion NDK stub libraries."
Treehugger Robot [Fri, 6 Jan 2017 20:39:21 +0000 (20:39 +0000)]
Merge "Unversion NDK stub libraries."

7 years agoUnversion NDK stub libraries.
Dan Albert [Fri, 6 Jan 2017 00:00:15 +0000 (16:00 -0800)]
Unversion NDK stub libraries.

The system versions of these libraries aren't versioned yet.

Bug: https://github.com/android-ndk/ndk/issues/278
Test: make ndk
Change-Id: I139f34217c8855a366ecb537bfabf2ca0181e4d3

7 years agoMerge "stagefright: parseApp check data boundary conditions"
Treehugger Robot [Thu, 5 Jan 2017 16:56:08 +0000 (16:56 +0000)]
Merge "stagefright: parseApp check data boundary conditions"

7 years agoMerge "Fix issue with 32 bit versions of asyncio"
Jerry Zhang [Thu, 5 Jan 2017 00:08:57 +0000 (00:08 +0000)]
Merge "Fix issue with 32 bit versions of asyncio"

7 years agoFix issue with 32 bit versions of asyncio
Jerry Zhang [Tue, 3 Jan 2017 22:41:56 +0000 (14:41 -0800)]
Fix issue with 32 bit versions of asyncio

Assuming 64 bit long offsets caused 32 bit tests
to fail

Test: verified async_io_test passes on 32 and 64 bit
Bug: 33846003
Change-Id: I2db126068037f674beeacd5bc30364010c858350

7 years agoMerge "HTTPLIVE: do not store hash of malformed M3U8 file"
Robert Shih [Wed, 4 Jan 2017 19:07:38 +0000 (19:07 +0000)]
Merge "HTTPLIVE: do not store hash of malformed M3U8 file"

7 years agoMPEG4Write mdhd duration overflow after recording for 15 hours
xiahong.bao [Thu, 29 Dec 2016 09:39:22 +0000 (17:39 +0800)]
MPEG4Write mdhd duration overflow after recording for 15 hours

MPEG4Write mdhd duration of AV track is larger than INT32_MAX
after record over 15 hours, so write mdhd box as version 1 type
which enhance duration to 64 bit.

Change-Id: I874b0a0ddfb7fb8f5b0a255345d8605b6c8ebf68
Signed-off-by: xiahong.bao <xiahong.bao@nxp.com>
7 years agostagefright: parseApp check data boundary conditions
Mark Salyzyn [Mon, 23 Jun 2014 21:13:22 +0000 (14:13 -0700)]
stagefright: parseApp check data boundary conditions

Test: compile, no poc for boundary violation.
Bug: 34056274
Change-Id: I23f5ccba8f211e01d9a3a741c8ea537b55aab4e2

7 years agoMerge "Add a mechanism for handling audio device configuration change"
Treehugger Robot [Wed, 28 Dec 2016 23:55:28 +0000 (23:55 +0000)]
Merge "Add a mechanism for handling audio device configuration change"

7 years agoAdd a mechanism for handling audio device configuration change
Pavlin Radoslavov [Tue, 27 Dec 2016 02:57:22 +0000 (18:57 -0800)]
Add a mechanism for handling audio device configuration change

* Added new call handleDeviceConfigChange() to the Media Framework.
  That call can be used when there are device configuration changes
  (e.g., Bluetooth A2DP codec configuration has changed).
* Added new method AudioPolicyManager::handleDeviceConfigChange().
  That method toggles the UNAVAILABLE/AVAILABLE connection state of the
  device, so it can be reconfigured as appropriate - e.g., the audio
  feeding parameters can be updated.
* Fix ALOGVV compilation errors when extra logging is enabled.

Test: A2DP streaming to headsets
Bug: 30958229
Change-Id: I388abbbb3ec4d1a003b441cb0c77e00d80cad668

7 years agoMerge "Replace cutils/log.h with either android/log.h or log/log.h"
Mark Salyzyn [Thu, 22 Dec 2016 18:26:17 +0000 (18:26 +0000)]
Merge "Replace cutils/log.h with either android/log.h or log/log.h"

7 years agoMerge "Make users of MtpServer provide DeviceInfo fields"
Alex Klyubin [Thu, 22 Dec 2016 17:06:06 +0000 (17:06 +0000)]
Merge "Make users of MtpServer provide DeviceInfo fields"

7 years agoReplace cutils/log.h with either android/log.h or log/log.h
Mark Salyzyn [Thu, 29 Sep 2016 15:48:48 +0000 (08:48 -0700)]
Replace cutils/log.h with either android/log.h or log/log.h

Test: compile
Bug: 31289077
Change-Id: I795a76f978d2213737f1fa908da789c543219b75

7 years agoHTTPLIVE: do not store hash of malformed M3U8 file
Jinguang Dong [Tue, 20 Dec 2016 06:33:39 +0000 (14:33 +0800)]
HTTPLIVE: do not store hash of malformed M3U8 file

From code analysis, we should make sure that M3UParser::initCheck
returns OK then perform hash memcpy. This would prevent NuPlayer from
overlooking a malformed M3U8 and crashing later on a NULL derefernce.

Test: 1 Play http://117.34.15.47/7d.v.iask.com/player/ovs1_idx_chid_1054589_br_400_fn_4_pn_weitv_sig_md5.m3u8
      2 mediaserver does not crash

Bug: 33763371
Change-Id: I3d8f5450cdf45288110121973c679c8d58210d5c

7 years agoMake users of MtpServer provide DeviceInfo fields
Alex Klyubin [Wed, 21 Dec 2016 19:20:22 +0000 (11:20 -0800)]
Make users of MtpServer provide DeviceInfo fields

This is part of weaning apps off accessing system identifiers via
system properties API. Apps should use android.os.Build API instead.

Bug: 33700679
Test: Enable MTP mode then check that mtp-detect output same as before this commit
Change-Id: Ic21da7b8e976aaa1abc606a3cb4a1f2bd8698408

7 years agoMerge "default no ouput verbose message of APM::AudioPolicyEngine/PFWWrapper"
Eric Laurent [Tue, 20 Dec 2016 16:15:44 +0000 (16:15 +0000)]
Merge "default no ouput verbose message of APM::AudioPolicyEngine/PFWWrapper"

7 years agoMerge "Fix issues with extractor dumpsys"
Treehugger Robot [Tue, 20 Dec 2016 00:05:46 +0000 (00:05 +0000)]
Merge "Fix issues with extractor dumpsys"

7 years agoMerge "Fix potential NULL dereference"
Treehugger Robot [Tue, 20 Dec 2016 00:00:33 +0000 (00:00 +0000)]
Merge "Fix potential NULL dereference"

7 years agoFix potential NULL dereference
Marco Nelissen [Mon, 19 Dec 2016 22:26:38 +0000 (14:26 -0800)]
Fix potential NULL dereference

Bug: 32875080
Change-Id: I9d6808812e735e58e8b477635441fd92f94f8d25

7 years agoFix issues with extractor dumpsys
Marco Nelissen [Mon, 19 Dec 2016 22:06:30 +0000 (14:06 -0800)]
Fix issues with extractor dumpsys

Tracks and descriptions were added to their respective lists in
opposite order, so dumpsys could mix up the format and active
state for a given track. Also fix potential NULL pointer dereference.

Bug: 33179012
Change-Id: I700d535da0e72f5641bf9257a34fdb5d5d068b12

7 years agoMerge "Fix unused-parameter warnings"
Treehugger Robot [Thu, 15 Dec 2016 20:24:16 +0000 (20:24 +0000)]
Merge "Fix unused-parameter warnings"

7 years agoMerge "Fix CameraParameters2::OrderedKeyedVector::removeItem tautological-compare"
Treehugger Robot [Thu, 15 Dec 2016 20:18:34 +0000 (20:18 +0000)]
Merge "Fix CameraParameters2::OrderedKeyedVector::removeItem tautological-compare"

7 years agoMerge "Fix mismatched-tags error"
Treehugger Robot [Thu, 15 Dec 2016 20:05:26 +0000 (20:05 +0000)]
Merge "Fix mismatched-tags error"

7 years agoFix unused-parameter warnings
Dan Willemsen [Wed, 14 Dec 2016 04:34:11 +0000 (20:34 -0800)]
Fix unused-parameter warnings

These are exposed when frameworks/av/include is moved from being a
system include directory to a normal include directory.

Test: m -j checkbuild
Change-Id: I0e3787fbee70339f7dcbc979f448800ecfff0f17
Merged-In: I0e3787fbee70339f7dcbc979f448800ecfff0f17

7 years agoFix mismatched-tags error
Dan Willemsen [Wed, 14 Dec 2016 04:32:25 +0000 (20:32 -0800)]
Fix mismatched-tags error

These are exposed when frameworks/av/include is moved from being a
system include directory to a normal include directory.

Test: m -j checkbuild
Change-Id: Iaa8f3808d578ebedc75e863b9818cfbbec9080b2
Merged-In: Iaa8f3808d578ebedc75e863b9818cfbbec9080b2

7 years agoFix CameraParameters2::OrderedKeyedVector::removeItem tautological-compare
Dan Willemsen [Wed, 14 Dec 2016 05:57:26 +0000 (21:57 -0800)]
Fix CameraParameters2::OrderedKeyedVector::removeItem tautological-compare

The tautological-compare warning/error is uncovered when
frameworks/av/include is moved from being a system header directory to a
normal include directory.

Test: m -j checkbuild
Change-Id: Ie2d6c354f11e162416a1ac5e8ea185fa62a959a0

7 years agoMerge "Fix warning: Called C++ object pointer is null"
Treehugger Robot [Wed, 14 Dec 2016 18:06:48 +0000 (18:06 +0000)]
Merge "Fix warning: Called C++ object pointer is null"

7 years agoMerge "Refactored Mtp driver interface into multiple classes."
Jerry Zhang [Tue, 13 Dec 2016 00:12:04 +0000 (00:12 +0000)]
Merge "Refactored Mtp driver interface into multiple classes."

7 years agoRefactored Mtp driver interface into multiple classes.
Jerry Zhang [Mon, 24 Oct 2016 19:10:41 +0000 (12:10 -0700)]
Refactored Mtp driver interface into multiple classes.

Added new interface for FunctionFS. This allows most of
the driver code to exist in userspace. The driver will
automatically use FunctionFS if it is enabled for that
device, otherwise it will default to the kernel driver.

The intention is to eventually deprecate the kernel driver.

Bug: 30976142
Change-Id: I36b8d16ca254fddd995b3ea1bd3d37b0ff4a28f7
Test: New automated tests for MtpFfsHandle, AsyncIO.
Manual testing on each device.

7 years agodefault no ouput verbose message of APM::AudioPolicyEngine/PFWWrapper
Liu Changcheng [Wed, 7 Dec 2016 10:58:19 +0000 (18:58 +0800)]
default no ouput verbose message of APM::AudioPolicyEngine/PFWWrapper

The verbose output consume much time. Change ALOGD to ALOGV in info
function. Developer could define LOG_NDEBUG to be 0 if need verbose
message to debug system

Change-Id: Iecb621d0eb8ec6a058608bf1b695b5ebd889c802
Signed-off-by: Liu Changcheng <changcheng.liu@intel.com>
Signed-off-by: Jerry Liu <primerlink@gmail.com>
7 years agoMerge "Log correct reason for camera connect failures"
Treehugger Robot [Thu, 8 Dec 2016 00:47:11 +0000 (00:47 +0000)]
Merge "Log correct reason for camera connect failures"

7 years agoFix warning: Called C++ object pointer is null
Yunlian Jiang [Wed, 7 Dec 2016 04:54:10 +0000 (20:54 -0800)]
Fix warning: Called C++ object pointer is null

Bug: None
Test: The warning is gone.
Change-Id: If33148cc1d8b0f3b26b39afdfc086d2abf18173d

7 years agoLog correct reason for camera connect failures
Tobias Lindskog [Tue, 1 Nov 2016 13:25:52 +0000 (14:25 +0100)]
Log correct reason for camera connect failures

Show the detailed error when we have it, rather than trying to show it
only when we don't.

Bug: 33358375
Change-Id: Ifa7a4f8de7b35a0379224efd1e27d6745844b853

7 years agoMerge "Add a mechanism for Audio Feeding Parameters negotiation"
Pavlin Radoslavov [Fri, 2 Dec 2016 07:37:05 +0000 (07:37 +0000)]
Merge "Add a mechanism for Audio Feeding Parameters negotiation"
am: 653748414b

Change-Id: Id6855d139a248d15ec0ea0ee0f01cf7655862ac7

7 years agoMerge "Add a mechanism for Audio Feeding Parameters negotiation"
Treehugger Robot [Fri, 2 Dec 2016 07:25:29 +0000 (07:25 +0000)]
Merge "Add a mechanism for Audio Feeding Parameters negotiation"

7 years agoAdd a mechanism for Audio Feeding Parameters negotiation
Pavlin Radoslavov [Tue, 22 Nov 2016 20:13:59 +0000 (12:13 -0800)]
Add a mechanism for Audio Feeding Parameters negotiation

Previously, the Audio Feeding Parameters between the Media Framework
and A2DP were hard-coded: 44.1 KHz sample rate, 16-bits per sample, Stereo.
Now the Media Framework queries A2DP, and uses the returned values.

Bug: b/30958229
Test: Manual testing: A2DP streaming to headphones. TestTracker/68727
Change-Id: Ib86035814c49f773b7ed3d64da334ca9ea87eb14

7 years agoMerge "Remove null-ptr deref compiler warning."
Caroline Tice [Thu, 1 Dec 2016 21:28:18 +0000 (21:28 +0000)]
Merge "Remove null-ptr deref compiler warning."
am: b4d217ed0f

Change-Id: Iaa009b250224afa46e7220c44054ae1755d897bd

7 years agoMerge "Remove null-ptr deref compiler warning."
Treehugger Robot [Thu, 1 Dec 2016 21:10:12 +0000 (21:10 +0000)]
Merge "Remove null-ptr deref compiler warning."

7 years agoRemove null-ptr deref compiler warning.
Caroline Tice [Thu, 1 Dec 2016 00:20:52 +0000 (16:20 -0800)]
Remove null-ptr deref compiler warning.

This CL removes the following compiler warning:
frameworks/av/media/libstagefright/MPEG4Extractor.cpp:1025:35
warning: Access to field 'next' results in a dereference of a null
pointer (loaded from variable 'cur')
[clang-analyzer-core.NullDereference]

Bug: None
Test: Compiled with change and no warning.
Change-Id: I365843068b098b111c281ac293a0b0b3aa2ec875

7 years agoMerge "Camera: fix camera facing override logic"
Yin-Chia Yeh [Wed, 30 Nov 2016 19:13:02 +0000 (19:13 +0000)]
Merge "Camera: fix camera facing override logic"
am: 853f568b31

Change-Id: I5028a6f298eb2c961556760b6ea248c673c13ba6

7 years agoMerge "Camera: fix camera facing override logic"
Treehugger Robot [Wed, 30 Nov 2016 19:00:16 +0000 (19:00 +0000)]
Merge "Camera: fix camera facing override logic"

7 years agoCamera: fix camera facing override logic
Yin-Chia Yeh [Tue, 29 Nov 2016 20:13:15 +0000 (12:13 -0800)]
Camera: fix camera facing override logic

Test: hack existing HAL to report EXTERNAL and run cts
Bug: 33091893
Change-Id: Idae8742fb4b18b2ef4842ec66284268fc650df22

7 years agoMerge "fix Potential leak of memory pointed to by 'sourcesLiteral'"
Yunlian Jiang [Wed, 23 Nov 2016 04:24:47 +0000 (04:24 +0000)]
Merge "fix Potential leak of memory pointed to by 'sourcesLiteral'"
am: fa81ba8775

Change-Id: I7d261ceb8cfce3b3f56ed907e1e32d70e7a40d45

7 years agoMerge "Fix null-pointer derefernce warning."
Caroline Tice [Wed, 23 Nov 2016 04:24:30 +0000 (04:24 +0000)]
Merge "Fix null-pointer derefernce warning."
am: 955e85294d

Change-Id: I492db6e2ea9cbe052f4120aba3477052ad791a29

7 years agoMerge "fix Potential leak of memory pointed to by 'sourcesLiteral'"
Treehugger Robot [Wed, 23 Nov 2016 04:18:14 +0000 (04:18 +0000)]
Merge "fix Potential leak of memory pointed to by 'sourcesLiteral'"

7 years agoMerge "Fix null-pointer derefernce warning."
Treehugger Robot [Wed, 23 Nov 2016 04:17:17 +0000 (04:17 +0000)]
Merge "Fix null-pointer derefernce warning."

7 years agoMerge "framework/av: fixbug for mistake clear mainbuffer data, root cause by not...
Jinguang Dong [Tue, 22 Nov 2016 18:41:21 +0000 (18:41 +0000)]
Merge "framework/av: fixbug for mistake clear mainbuffer data, root cause by not offset to fout"
am: 25ef483a8c

Change-Id: I6c8ee1c28b51f1578a781fdc7dd1d51326046d2f

7 years agoMerge "framework/av: fixbug for mistake clear mainbuffer data, root cause by not...
Treehugger Robot [Tue, 22 Nov 2016 18:37:03 +0000 (18:37 +0000)]
Merge "framework/av: fixbug for mistake clear mainbuffer data, root cause by not offset to fout"

7 years agoframework/av: fixbug for mistake clear mainbuffer data,
Jinguang Dong [Mon, 14 Nov 2016 11:57:14 +0000 (19:57 +0800)]
framework/av: fixbug for mistake clear mainbuffer data,
root cause by not offset to fout

Test: 1. pair and connect with bluetooth ear phone;
      2. record video by camera ,play and pause again by
      loop test;
      3. Checking whether ear phone has pop sound.

Change-Id: Ief4117d634b9e7a9f27c669b8de7626b15df7636

7 years agoMerge "Remove LOCAL_COPY_HEADERS from libparameter"
Dan Willemsen [Fri, 18 Nov 2016 23:28:33 +0000 (23:28 +0000)]
Merge "Remove LOCAL_COPY_HEADERS from libparameter"
am: 76321a335c

Change-Id: Ie99187aa91ddb1a9fa199dcf681edd4565cc0d1b

7 years agoMerge "Remove LOCAL_COPY_HEADERS from libparameter"
Treehugger Robot [Fri, 18 Nov 2016 23:19:25 +0000 (23:19 +0000)]
Merge "Remove LOCAL_COPY_HEADERS from libparameter"

7 years agoRemove LOCAL_COPY_HEADERS from libparameter
Dan Willemsen [Fri, 18 Nov 2016 21:28:36 +0000 (13:28 -0800)]
Remove LOCAL_COPY_HEADERS from libparameter

Requires the libaudiopolicypfwwrapper to depend on libparameter to get
the exported headers. Also fix the libaudiopolicyengineconfigurable
build to resolve missing liblog symbols.

Test: USE_CONFIGURABLE_AUDIO_POLICY=1 mmma -j frameworks/av/services/audiopolicy

7 years agoMerge "Camera3: Add missing mTriggerMutex lock"
Jinguang Dong [Thu, 17 Nov 2016 19:12:18 +0000 (19:12 +0000)]
Merge "Camera3: Add missing mTriggerMutex lock"
am: ad4663c5a5

Change-Id: I59b7de9cdd9f608afa503293947a19d3f11d533b

7 years agoMerge "Camera3: Add missing mTriggerMutex lock"
Treehugger Robot [Thu, 17 Nov 2016 19:02:13 +0000 (19:02 +0000)]
Merge "Camera3: Add missing mTriggerMutex lock"

7 years agoMerge "httplive: fix overflow in BandwidthEstimator"
Robert Shih [Thu, 17 Nov 2016 17:54:42 +0000 (17:54 +0000)]
Merge "httplive: fix overflow in BandwidthEstimator"
am: 6cc43e10f4

Change-Id: I62c07442b4bcb05fa067e879c445bf19d4832b13

7 years agoMerge "httplive: fix overflow in BandwidthEstimator"
Robert Shih [Thu, 17 Nov 2016 17:43:36 +0000 (17:43 +0000)]
Merge "httplive: fix overflow in BandwidthEstimator"

7 years agoCamera3: Add missing mTriggerMutex lock
Jinguang Dong [Mon, 14 Nov 2016 08:04:02 +0000 (16:04 +0800)]
Camera3: Add missing mTriggerMutex lock

There is thread safety problem for mTriggerMap in
Camera3Device::RequestThread::clear(). For correctness,
acquire mTriggerMutex before mTriggermap.clear().

Test: 1. Configure power saving mode to 2 seconds by
      modification software;
      2. using pyhon or monkey to turn on the screen every 4
      second;
      3. device doesn't crash any more on loop test.

Change-Id: I2f04e21dae3a9879d6cebfefb9d9c191ef3f4df4

7 years agoMerge "fix Access to field 'targets' results in a dereference of a null pointer"
Yunlian Jiang [Wed, 16 Nov 2016 04:17:57 +0000 (04:17 +0000)]
Merge "fix Access to field 'targets' results in a dereference of a null pointer"
am: caea9fc26a

Change-Id: Id38c914a250aab0b4a395739db7e700c821ddaf3

7 years agoMerge "fix Access to field 'targets' results in a dereference of a null pointer"
Treehugger Robot [Wed, 16 Nov 2016 04:08:57 +0000 (04:08 +0000)]
Merge "fix Access to field 'targets' results in a dereference of a null pointer"

7 years agoFix null-pointer derefernce warning.
Caroline Tice [Wed, 16 Nov 2016 02:03:48 +0000 (18:03 -0800)]
Fix null-pointer derefernce warning.

Fixes IOMX.cpp:599  warning: Dereference of null pointer

BUG: None
Test: Warning is now gone.
Change-Id: Ife4a8d8af9b2eccd020448ac2ad4c65de081eb4c

7 years agofix Potential leak of memory pointed to by 'sourcesLiteral'
Yunlian Jiang [Wed, 16 Nov 2016 01:55:57 +0000 (17:55 -0800)]
fix Potential leak of memory pointed to by 'sourcesLiteral'

Bug: none
Test: the warning is gone.
Change-Id: I8fe9610e24e31e3f788d00fa7f594e1274771433

7 years agofix Access to field 'targets' results in a dereference of a null pointer
Yunlian Jiang [Wed, 16 Nov 2016 01:52:15 +0000 (17:52 -0800)]
fix Access to field 'targets' results in a dereference of a null pointer

This fixes Access to field 'targets' results in a dereference of a null
pointer

Test: the warning is gone.
Change-Id: If5d8c1c87c4cf77252bd5d262eefeba30c772fe7

7 years agohttplive: fix overflow in BandwidthEstimator
Robert Shih [Mon, 14 Nov 2016 19:23:49 +0000 (11:23 -0800)]
httplive: fix overflow in BandwidthEstimator

Bug: 32424616
Change-Id: If857fec44c6466aaadbde8cccbbf95a98d231fa2

7 years agoMerge "Avoid crash for stss sync sample number 0"
Roger1 Jonsson [Sat, 12 Nov 2016 02:32:41 +0000 (02:32 +0000)]
Merge "Avoid crash for stss sync sample number 0"
am: 11f51b0463

Change-Id: I923fe096f4b9fef2d9b5b3a6e5674a0283b9f65e

7 years agoMerge "Avoid crash for stss sync sample number 0"
Treehugger Robot [Sat, 12 Nov 2016 02:22:29 +0000 (02:22 +0000)]
Merge "Avoid crash for stss sync sample number 0"

7 years agoMerge "mediacodec/mediaextractor: allow multiple Seccomp extensions"
Alex Naidis [Fri, 11 Nov 2016 17:39:39 +0000 (17:39 +0000)]
Merge "mediacodec/mediaextractor: allow multiple Seccomp extensions"
am: da4cb8cb6c

Change-Id: Ia85752fe429a0fbb985ca0ad5425029c0a2811cf

7 years agoMerge "mediacodec/mediaextractor: allow multiple Seccomp extensions"
Treehugger Robot [Fri, 11 Nov 2016 17:29:02 +0000 (17:29 +0000)]
Merge "mediacodec/mediaextractor: allow multiple Seccomp extensions"

7 years agomediacodec/mediaextractor: allow multiple Seccomp extensions
Alex Naidis [Sat, 29 Oct 2016 14:18:15 +0000 (16:18 +0200)]
mediacodec/mediaextractor: allow multiple Seccomp extensions

This is useful if we have multiple device
layers and want to have common extensions while
supporting device specific extensions at the same time.

Change-Id: Iefbff9c1ec680963a7ea4c2db09d8e888dd87703
Signed-off-by: Alex Naidis <alex.naidis@linux.com>
7 years agoMerge "Override Auxiliary audio effect output as stereo"
Ricardo Garcia [Thu, 10 Nov 2016 15:13:35 +0000 (15:13 +0000)]
Merge "Override Auxiliary audio effect output as stereo"
am: 568085d022

Change-Id: I4f705ee2b47f30731d4f1ac46213fbcd678633a5

7 years agoMerge "Override Auxiliary audio effect output as stereo"
Ricardo Garcia [Thu, 10 Nov 2016 15:04:10 +0000 (15:04 +0000)]
Merge "Override Auxiliary audio effect output as stereo"

7 years agoOverride Auxiliary audio effect output as stereo
Yuuki Yokoyama [Tue, 23 Aug 2016 08:11:03 +0000 (17:11 +0900)]
Override Auxiliary audio effect output as stereo

Auxiliary audio effect supports only stereo as output channel.
Override output channel in case of Auxiliary effect.

Bug: 31985321
Change-Id: I308a6281e2ae2b8f814a659aa40dc6220ab7660a

7 years agoAvoid crash for stss sync sample number 0
Roger1 Jonsson [Wed, 26 Oct 2016 07:20:00 +0000 (09:20 +0200)]
Avoid crash for stss sync sample number 0

A sample number value of 0 means that the value stored in
the mSyncSamples array, would become negative (-1),
when converted to index value. This causes a crash.

Make sure that stss sample numbers are bigger
than 0 before converting sample number to index value.

Bug: 32423862
Test: Playback video that triggers stss sync sample number 0
Change-Id: I35bee7c718e01b086d7e05deda13b38083f509f5