Commit graph

365 commits

Author SHA1 Message Date
Elliott Hughes
06b402dd10 am ac41815a: Merge "Add missing includes."
* commit 'ac41815a99763b3e59d0f2f9ef2bb3e5a2011336':
  Add missing includes.
2015-01-30 21:16:31 +00:00
Elliott Hughes
07c085565a Add missing includes.
Change-Id: I91730363386dae6ecb2193ec8f50ba9f8fc0ad60
2015-01-29 21:19:10 -08:00
Elliott Hughes
588f725985 am f4530d6e: Merge "Add missing includes."
* commit 'f4530d6eed5fa432fe9283355a265a38aea58bc6':
  Add missing includes.
2015-01-29 05:21:41 +00:00
Elliott Hughes
84b9ff8b1c Add missing includes.
Change-Id: Ia74cceea707e51195a570eed37d4b334ac413773
2015-01-28 19:54:13 -08:00
Eric Laurent
e64994292c Merge commit '83b47a68' into manualmerge 2015-01-09 17:04:40 -08:00
Pavan Chikkala
83b47a6891 usb audio: Fix incorrect bytes returned for recording
In a recording session , the number of bytes read is
not updated when pcm_read() fails. This results in
silence/invalid data being added during a device switch
from USB headset to handset.
Fix is to reset the number of bytes read if pcm_read()
returns an error indicating removal of USB headset.

Bug: 18611518

Change-Id: I10d578c3cf1037c90a891e63be2bd1c2b7e6126b
2015-01-09 14:14:41 -08:00
Eric Laurent
7e9abab194 am b338957d: Merge "usbaudio: Return 0 bytes on failure in capture"
* commit 'b338957d02528e5b51a15c5ce21e96fad4ff4a6f':
  usbaudio: Return 0 bytes on failure in capture
2015-01-09 17:58:33 +00:00
Viswanath L
8c7e1114a3 usbaudio: Return 0 bytes on failure in capture
Return 0 bytes from in_read() in failure conditions so that invalid
data is not recorded.

Change-Id: I9a6294e4162fa642fd7e160a32d1ad16f255ff62
2015-01-09 22:38:54 +05:30
Elliott Hughes
06fcfc506c am 02e30945: Merge "Fix missing #includes in hardware/libhardware."
* commit '02e3094598ced8b05c9614d6070556d20328ef43':
  Fix missing #includes in hardware/libhardware.
2014-12-30 12:21:17 +00:00
Elliott Hughes
6cdd2b37d7 Fix missing #includes in hardware/libhardware.
Change-Id: If7c72054bf79b89c3d7a544956da671c3b404269
2014-12-29 12:59:11 -08:00
Eric Laurent
68be24b1cc am ce0bbb97: Merge "fix: memory leak"
* commit 'ce0bbb97c12b712b75d0df42ce2f6e3f35d8db72':
  fix: memory leak
2014-12-18 21:50:36 +00:00
soon1.choi
781bb3f72e DO NOT MERGE - fix: memory leak
free momory for str_parms to prevent memory leak.

cherry-pcik from aosp c357157e28

Bug: 18798194.

Change-Id: I7df5567d665554dbd4646c881f0f48b0c568c5fe
2014-12-18 09:55:05 -08:00
Eric Laurent
ce0bbb97c1 Merge "fix: memory leak" 2014-12-18 16:42:11 +00:00
soon1.choi
c357157e28 fix: memory leak
free momory for str_parms to prevent memory leak.

Change-Id: I7df5567d665554dbd4646c881f0f48b0c568c5fe
2014-12-18 16:03:43 +09:00
Ying Wang
14a4dd8907 am cecfb56c: Merge "Cleanup Obsolete LOCAL_PRELINK_MODULE."
* commit 'cecfb56c5192fe1517a8e1b5910f16961db4a231':
  Cleanup Obsolete LOCAL_PRELINK_MODULE.
2014-12-16 20:53:38 +00:00
Ying Wang
23853ead7d Cleanup Obsolete LOCAL_PRELINK_MODULE.
Bug: 18675947
Change-Id: I62157cd4bfab0edb445dd6543eb47a981e642848
2014-12-16 12:33:37 -08:00
Haynes Mathew George
5c8b899d7c am 2cbdfa9c: usbaudio: reset profile on device disconnect
* commit '2cbdfa9c991fc63f52f48831e5509fcc2889db77':
  usbaudio: reset profile on device disconnect
2014-12-12 14:39:15 +00:00
Haynes Mathew George
2cbdfa9c99 usbaudio: reset profile on device disconnect
Reset ALSA device profile on disconnect event. Entries like
supported sample rates, channel counts, formats will be repopulated
on next connect.

CRs-Fixed: 765434
Change-Id: I27d3b7fd7ff22646996f58c53de08547b1a1fb6a
Bug: 18606219
2014-12-11 09:14:19 -08:00
Jean-Michel Trivi
de148628b9 am 257fde6e: Reroute submix HAL: fix race condition on output state
* commit '257fde6eb533b890776c8c45be8b61c48ab04945':
  Reroute submix HAL: fix race condition on output state
2014-12-10 22:36:20 +00:00
Jean-Michel Trivi
257fde6eb5 Reroute submix HAL: fix race condition on output state
When reading from a pipe, the output may have been previously
 closed, therefore the output state should only be read if it
 is still available.
This fixes a race condition observed between in_read() (which
 accesses the output stream) and adev_close_output_stream()
 (which sets the output reference to NULL).
 No issue with out_write() which checks the input reference.

Bug 16009464

Change-Id: I979bc12c8fe91fad9b6f6c9e0be107c1bacae360
2014-12-09 20:27:11 -08:00
Elliott Hughes
c5f5daffb5 am 719b8423: Merge "Remove ARCH_X86."
* commit '719b8423102e469b5a537321f02011415b376dbe':
  Remove ARCH_X86.
2014-12-05 18:01:52 +00:00
Elliott Hughes
719b842310 Merge "Remove ARCH_X86." 2014-12-05 17:47:29 +00:00
Elliott Hughes
65d51a15a7 Remove ARCH_X86.
Should have been __GLIBC__, but the code is dead anyway.

Change-Id: I773f296a9c31949fa631cad863b841584c71f0ef
2014-12-04 16:20:52 -08:00
Dan Albert
df44fe72a6 am 32fb8b2d: Merge "Fix C++11 build."
* commit '32fb8b2d9f8399a745a26dddc031cc16867ada2d':
  Fix C++11 build.
2014-11-28 06:05:03 +00:00
Dan Albert
9a8c57a346 Fix C++11 build.
Not sure how this slipped past my checkbuild...

Change-Id: Id238887a2a47ced387a6128a772fad3e468096be
2014-11-27 21:39:46 -08:00
Jean-Michel Trivi
591343449a am b73bc860: Support multiple pipes for rerouting
* commit 'b73bc86089b8a65da88776bafcf48529431150b8':
  Support multiple pipes for rerouting
2014-11-19 19:32:18 +00:00
Jean-Michel Trivi
b73bc86089 Support multiple pipes for rerouting
The implementation for "remote submix" supported only one pipe
  to capture the output of a mix.
This CL adds support for multiple pipes to support capturing
  multiple audio routes.
The structure for the r_submix audio device holds an array
  of route configurations (route_config), each referencing
  the input and output of the pipe dedicated to this route.
  Each route is associated to a unique address. Standby
  status is maintained per stream.

Bug 16009464

Change-Id: Ie164c4ad2a6d8138f825484e7faf29a974ccf82e
2014-11-17 17:04:45 -08:00
Dan Albert
be9083bd65 am 40d48e17: Merge "Stop using stlport."
* commit '40d48e177f243c6093a45301db122a0475cc1124':
  Stop using stlport.
2014-11-17 22:58:58 +00:00
Dan Albert
6d604b127e Stop using stlport.
Bug: 15193147
Change-Id: I5d53338f239ba18a2b007b345ba050d1560220b4
2014-11-17 14:21:50 -08:00
Jean-Michel Trivi
4b6c515509 am 5ff76cb5: am 793a854e: Fix remote submix crash on null sink
* commit '5ff76cb59a892a856fa2476bd5bf7c41537b78e1':
  Fix remote submix crash on null sink
2014-10-16 05:52:39 +00:00
Jean-Michel Trivi
5ff76cb59a am 793a854e: Fix remote submix crash on null sink
* commit '793a854e4547fa43632907a987684cadc93eb5e2':
  Fix remote submix crash on null sink
2014-10-15 23:41:09 +00:00
Jean-Michel Trivi
793a854e45 Fix remote submix crash on null sink
The "remote submix" HAL uses a MonoPipe instance to "pipe" audio
  from the sink of this virtual device HAL to its source.
  The life-cycle of this pipe is:
  - creation when either the input or output stream is open
  - destruction when both input and output are closed.

Changes are:
Fix test for pipe destruction: destroy pipe when both
  input and output streams are NULL.
Count how many read errors went into the logs and cap them
  so as not to spam the logs when the pipe is not properly
  set up. Less 'I' logs, 'D' logs instead.
When opening input stream, check for non-null sink before
  checking if it's shutdown.

Bug 16653334
Bug 17111907

Change-Id: I634b4192b00f9b74a5109f42242423e9c8cb4c7c
2014-10-15 15:16:10 -07:00
Nick Vaccaro
6b82558129 am e914d696: Report multihal is SENSORS_DEVICE_API_VERSION_1_3 compliant
* commit 'e914d696a95a799bbcca221238a1874f995871ca':
  Report multihal is SENSORS_DEVICE_API_VERSION_1_3 compliant
2014-10-11 02:49:27 +00:00
Nick Vaccaro
e914d696a9 Report multihal is SENSORS_DEVICE_API_VERSION_1_3 compliant
Ignore calls to any HALs that are not 1_0 or 1_3 compliant.
Fix an unused parameter compiler warning.

Bug: 17645248
Change-Id: Ia50f7512dfe35f37973440bba84e1b1b177a7bd3
2014-10-10 16:02:26 -07:00
Paul McLean
2cfd81bae0 Support MONO and STERO USB inputs. Allow "dynamic" flag in audio_policy.conf.
Bug 17526569

Change-Id: I64b00fd338eb937303b41608728a18341ee78820
2014-09-17 08:38:57 -07:00
Eric Laurent
253def9fa0 usb audio: implement microphone mute.
Bug: 17321604.
Change-Id: I8e3daf2636dfd5f85d990c0093c52c908064afac
2014-09-14 12:32:28 -07:00
Paul McLean
0f519a9e5e Merge "Fix problem with dropouts with multiple USB audio streams." into lmp-dev 2014-08-28 20:44:42 +00:00
Paul McLean
c48cdc8ec0 Fixing non-playback on USB devices with support for MONO playback.
Bug 17136854

Change-Id: Ia0136fa8f9b4789d538b2dccb3f6071ae5062010
2014-08-28 09:16:39 -07:00
Paul McLean
2c6196f20c Fix problem with dropouts with multiple USB audio streams.
Bug 17136569

Change-Id: I94bdbe037533a3fd77f249fdd42f4d828d3bf87f
2014-08-28 07:59:03 -07:00
Glenn Kasten
8f40bc5599 Merge "Quick hack fix for USB accessory audio support" into lmp-dev 2014-08-21 15:35:20 +00:00
Mike Lockwood
7de76b2d4d Quick hack fix for USB accessory audio support
tinyalsa fails to retrieve the correct value for the period count
from the f_audio_source driver and tries to use zero instead.
This wasn't a problem before because the usb audio HAL used hard coded values
that were compatible with the driver.

Bug: 16799652
Change-Id: I6f5b907a0699c58b071e9f419ed8e053a7d9dc77
2014-08-21 14:51:29 +00:00
Paul McLean
93d4e0db0e Fix problem with reloading config of new capture devices
with same card/device numbers.

Bug: 17012657
Change-Id: I7cb50aedc538d8c648e7f66c8e153cf47ce12577
2014-08-13 23:08:41 +00:00
Paul McLean
af5187efbd Fix problem with reloading config of new devices with same card/device numbers.
Bug 16981885

Change-Id: I65c6c418ee0d0f42c87379b614f64302d27f8e77
2014-08-12 13:57:10 -07:00
Eric Laurent
05333d458d usb audio: fix set_parameters read/write concurrency
Do not read the ALSA PCM device configuration when playback
or capture is active.
Do not force ALSA profile update if card and device passed
to out/in_set_parameters() do not change.
Hold the main HAL lock when closing or opening the
ALSA PCM device.

Bug: 15520724.

Change-Id: I2b6087ed46ce7433de0b6dd8b24ec10de2e55d21
2014-08-06 14:18:26 -07:00
Eric Laurent
83cd830918 sound_trigger HAL update
Bug: 12378680.

Change-Id: I556cd316cbff3b8d88331319ca0ad65a09aae0f9
2014-07-31 11:16:16 -07:00
Andy Hung
2352f41f9d Merge "Pass multichannel capability to AudioPolicyManager" into lmp-dev 2014-07-29 21:36:00 +00:00
Andy Hung
ce53d748a3 Pass multichannel capability to AudioPolicyManager
Change-Id: Ifcfe5e9e0c01ccb0e9af25e0c718ea5f04181ae4
2014-07-29 09:50:26 -07:00
Andy Hung
03576bed81 Add multichannel USB handshaking with AudioFlinger
The number of channels can be "forced" using k_force_channels.
If the channel count proposed by AudioFlinger is not permitted
by the device, it is emulated.

Change-Id: Ib20e680c8f95adb84616a4fe52977f659cf4d6ca
2014-07-28 17:37:46 -07:00
Andy Hung
b52eff359f Merge "Add multichannel USB handshaking with AudioFlinger" into lmp-dev 2014-07-28 22:45:16 +00:00
Jeff Brown
d61f84efe2 Delete mcu HAL.
This HAL was intended to support doze mode but it is currently
unused and it's best for it to stay that way.

Bug: 16516536
Change-Id: I4f442e27d68f18ff322afd4c1debd2f392687e80
2014-07-26 14:58:23 -07:00