65587 Commits

Author SHA1 Message Date
John Wang
78308ca1b4 am 63b59666: Merge "Only use CDMA rssi for config_alwaysUseCdmaRssi." into ics-mr1
* commit '63b596664c3fdb70ad32c8f641f477ec9140d6ec':
  Only use CDMA rssi for config_alwaysUseCdmaRssi.
2012-02-14 12:37:49 -08:00
John Wang
63b596664c Merge "Only use CDMA rssi for config_alwaysUseCdmaRssi." into ics-mr1 2012-02-14 10:09:26 -08:00
John Wang
d55cde1384 Only use CDMA rssi for config_alwaysUseCdmaRssi.
If config_alwaysUseCdmaRssi is true, the RSSI signal bar only
shows the CDMA value, no matter it connects to EVDO or WiMax .

bug:5941743
Change-Id: I4187571898a9fb47162e1ccf0cc4c59c3136ae0b
2012-02-13 17:48:24 -08:00
Mike Lockwood
c4ddf2fd5f Merge "WifiStateTracker: add support for overriding DCHP max retry count in an overlay" into ics-aah 2012-02-13 14:30:45 -08:00
Mike Lockwood
11046a2a4b WifiStateTracker: add support for overriding DCHP max retry count in an overlay
Bug: 5551068

Change-Id: I7817eeb1409af2056a63548104c3c64f93ee7def
Signed-off-by: Mike Lockwood <lockwood@google.com>
2012-02-13 14:08:50 -08:00
John Grossman
6927efc5ad Merge "Put a bandaid on a segfault in timed audio track handling." into ics-aah 2012-02-13 14:07:17 -08:00
Tsu Chiang Chuang
9dfb0c6c65 am 08eb7dd6: Merge "extending timeout to stabilize tests" into ics-mr1
* commit '08eb7dd630a2de8dd51a988a747da26ff9d3f8fb':
  extending timeout to stabilize tests
2012-02-13 13:43:34 -08:00
Tsu Chiang Chuang
08eb7dd630 Merge "extending timeout to stabilize tests" into ics-mr1 2012-02-13 13:41:37 -08:00
John Grossman
e1288ffbf2 Put a bandaid on a segfault in timed audio track handling.
Add a bandaid to prevent a segfault which can occur while handling
timed audio buffers.  There is a deeper problem which should
eventually be addressed, but for now this fix should prevent any
crashing.

The deeper problem is as follows.

When the AudioFlinger mixer gets data to mix from an AudioTrack, it
ends up getting a structure filled out which points into an IMemory
region owned by the AudioTrack.  Unfortunately, this structure is not
holding a refcount on the IMemory which it points into.  If the
IMemory refcount hits 0 and the chunk of RAM is retuned to the binder
heap it came from, there can still be a Buffer object being held by
the AudioFlinger mixer which points into the region of memory which
was retuned to the binfer heap.  If AF reads from this buffer, it
could read corrupt data (if the region of memory gets handed back out
to a writer), or it could segfault (if the heap has been freed and the
pages unmapped).  Similar problems could happen if AF attempts to
write to the buffer, heap corruption in one case, segfaulting in the
other.

In the past, this has not been an issue for AF, because tracks
allocate a single IMemory (which serves as a ring buffer) and the
IMemory lives for as long as the track lives.  As an artifact of the
way the code came out, the mixer cannot be holding a Buffer structure
pointing into the IMemory which used to be owned by a track if the
track no longer exists.  Tracks cannot come into or out of existence
during a mix operation, which is the only thing which makes this safe.

TimedTracks work differently, however.  Timed tracks each allocate a
small binder heap, and then hand out IMemory instances  broken out of
this heap.  The heap lives as long as the track, so the worst which
could happen here is that a TimedTrack's IMemory gets returned to the
heap while there is still a buffer structure in flight pointing into
the memory region, then the region gets handed out again and
overwritten by new data causing the mixer to mix the wrong audio.  The
timing to cause this to happen is very difficult to encounter, and you
to generate the timing conditions required, you need to be in a pretty
bad failure state where audio is already breaking up and skipping, so
its unlikely that anyone would notice (which is why I'm band-aiding
the segfault and letting the deeper issue slide for now).

In general, however, it might be a good idea to revisit this buffering
design.  On principal, if someone is going to hold pointers into a
refcounted object, they should be holding a ref on the object at the
same time.  Failure to do this will usually lead to a situation where
there are corruption or segfault issues, or to a system where the
refcounted object's lifetime must be implicitly managed very carefully
in ways which are usually non-obvious and are easy to break by new
engineers on a project.

Change-Id: Ib391075395ed0ef46a03c37aa38a82d09e88abeb
2012-02-12 17:51:21 -08:00
Wink Saville
673b352f6b am 197fe269: Merge "Add OEM specific USB mode enumeration based on ro.bootmode property" into ics-mr1
* commit '197fe26940022be75384f4038dd789f446d33122':
  Add OEM specific USB mode enumeration based on ro.bootmode property
2012-02-10 15:14:06 -08:00
Wink Saville
197fe26940 Merge "Add OEM specific USB mode enumeration based on ro.bootmode property" into ics-mr1 2012-02-10 15:12:19 -08:00
Eric Fischer
4e2a6ae15f am 650462bb: Import revised translations. DO NOT MERGE
* commit '650462bbfd6218c918cd9507ea0a33fa9a936f26':
  Import revised translations.  DO NOT MERGE
2012-02-10 13:11:03 -08:00
Eric Fischer
650462bbfd Import revised translations. DO NOT MERGE
Change-Id: Ibfc588d17f79baa0359d3a20a0a5ff7a2f3f152b
2012-02-10 12:29:26 -08:00
Kazuhiro Ondo
afd8f1820e Add OEM specific USB mode enumeration based on ro.bootmode property
This patch is adding a capability so that OEM can override USB mode
in case the device is boot up with OEM specific mode. (i.e. modem
debug, factory test etc.)

Bug:5964042
Change-Id: Ic8e23d302563ce71eedb74ce94cca8c65838a4f7
2012-02-10 12:29:12 -08:00
Justin Ho
7f3b28f58c am 744c5b0b: Merge "Import translations. DO NOT MERGE" into ics-mr1
* commit '744c5b0bdee6a26e2dc7e740a695d53c32104326':
  Import translations. DO NOT MERGE
2012-02-10 10:09:58 -08:00
Justin Ho
744c5b0bde Merge "Import translations. DO NOT MERGE" into ics-mr1 2012-02-10 10:07:07 -08:00
Scott Main
999b646bd3 am d9c8bbd5: docs: fix xss issue bug 5125642
* commit 'd9c8bbd56a9c76a111f9441871e79516c521aa75':
  docs: fix xss issue bug 5125642
2012-02-09 16:01:25 -08:00
Scott Main
d9c8bbd56a docs: fix xss issue
bug 5125642

Change-Id: I326b619643e3b3de20aa9303e92c9218fdfe50f7
2012-02-09 15:57:09 -08:00
Joe Fernandez
da13251fac am 1c66faab: Merge "docs: OpenGL Tutorials fixed two broken links (Issue 5990696, public android bug: 25132)" into ics-mr1
* commit '1c66faab73b2ce54bfe362f3c051ce95ed89fb22':
  docs: OpenGL Tutorials fixed two broken links (Issue 5990696, public android bug: 25132)
2012-02-09 13:46:57 -08:00
Joe Fernandez
1c66faab73 Merge "docs: OpenGL Tutorials fixed two broken links (Issue 5990696, public android bug: 25132)" into ics-mr1 2012-02-09 13:45:01 -08:00
Scott Main
dfa926f54b am 52bfc243: docs: fix misc doc bugs from external issue tracker
* commit '52bfc243684b2f340da326aaa38e9021e4e3b2e6':
  docs: fix misc doc bugs from external issue tracker
2012-02-09 12:48:18 -08:00
Scott Main
52bfc24368 docs: fix misc doc bugs from external issue tracker
Change-Id: If6ff3476670e42b321d56d4a1482ccff96d4d500
2012-02-09 12:45:16 -08:00
John Grossman
b859d83bc9 Merge "Fix a segfault in AudioFlinger." into ics-aah 2012-02-09 11:51:51 -08:00
John Grossman
2cb8784d03 Fix a segfault in AudioFlinger.
Check the string returned by a HAL's implementation of get_parameters
for NULL before attempting to make use of it.  That way, we won't
bring down the mediaserver because of a poorly written HAL.

Change-Id: I45f0fd3de003151f98acf32c36c42f58d053f3a0
2012-02-09 11:31:06 -08:00
Mike Lockwood
0e8392e1dc Add support for non-linear ramping of master volume adjustment
Bug: 5472584

Change-Id: Id75f8835f6693ae3fcb7ca451ada01f22faba1aa
Signed-off-by: Mike Lockwood <lockwood@google.com>
2012-02-09 11:24:10 -08:00
Joe Fernandez
a61f842040 docs: OpenGL Tutorials fixed two broken links (Issue 5990696, public android bug: 25132)
Change-Id: I9d504017c507b2e203b8e0448d720714bec32e8c
2012-02-09 11:16:20 -08:00
Eric Fischer
e42fe553a7 Import translations. DO NOT MERGE
Change-Id: Id6eb7d951bbbd8d01ce11670946282eecd7bc984
2012-02-08 18:46:47 -08:00
Xia Wang
4dd8338b8d Merge "Remove airplane mode related wifi test for Wi-Fi only devices." into ics-aah 2012-02-08 10:08:23 -08:00
Scott Main
7f6b378c75 am 09ff04d7: docs: fix typo in menu TOC
* commit '09ff04d7893a9f49e478bb732ce1ea1b17662a3b':
  docs: fix typo in menu TOC
2012-02-07 21:48:18 -08:00
Scott Main
09ff04d789 docs: fix typo in menu TOC
Change-Id: Ief511803ef5b4bed1823a12918de814aca119681
2012-02-07 21:45:00 -08:00
John Grossman
583a03ac04 Fix device ID selection in the common time service.
Fix an issue I discovered while back-porting this code to master.  The
common time service was using the MAC address of "eth0" (hardcoded) as
its device ID instead of fetching it from the interface it is
currently bound to.  On phones (or any other device with no eth0) this
causes time service to never be able to fetch a device ID as it
should.

Change-Id: Icf8a2006924088efc86065927a648f7f53638657
2012-02-07 16:07:48 -08:00
Xia Wang
8e2b887567 Remove airplane mode related wifi test for Wi-Fi only devices.
Change-Id: I7304276af7cb1dad0f08ebc9738108e877525eb9
2012-02-07 14:19:56 -08:00
John Grossman
e7509ae668 Merge "Explicitly manage common clock client lifetimes." into ics-aah 2012-02-06 18:12:56 -08:00
John Grossman
06e51360ec Merge "Add the CommonTimeManagementService." into ics-aah 2012-02-06 18:12:39 -08:00
John Grossman
89843c251b Merge "Implement new common_time service functionality." into ics-aah 2012-02-06 18:12:30 -08:00
John Grossman
134e6c9336 Merge "Add Java interfaces to the common_time services." into ics-aah 2012-02-06 18:12:21 -08:00
John Grossman
8b667490cd Merge "Add native common time config service." into ics-aah 2012-02-06 18:12:14 -08:00
John Grossman
008bb41946 Merge "Add marshallers for the new common clock methods." into ics-aah 2012-02-06 18:11:58 -08:00
John Grossman
2760e17da5 Merge "Change ICommonClock marshallers to return explicit error codes." into ics-aah 2012-02-06 18:11:52 -08:00
John Grossman
ad8b498417 Merge "Move the definition of time server state." into ics-aah 2012-02-06 18:11:46 -08:00
John Grossman
dfedbb9e76 Merge "De-AAH-ify the common time service." into ics-aah 2012-02-06 18:11:40 -08:00
John Grossman
36d372fb6a Explicitly manage common clock client lifetimes.
Change the CCHelper class to be an instanced instead of a static
pattern.  The CCHelper instances all share an interface to the common
clock service and register/unregister a callback handler in response
to there being CCHelper instance in the system or not.  This brings
usage of the CCHelper into like with the new auto-disable
functionality of the common time service.  For any given process,
whenever there are CCHelper instances active, the process will
maintain a callback target to the common clock service and will be
considered to be an active client.

Also change all of the users of the CCHelper interface to manage the
lifecycle of their new CCHelper instances.

Change-Id: I7c28c5d70d9b07ba7407b4ac706e7e7d7253001b
2012-02-06 18:02:33 -08:00
John Grossman
7d6934f3eb Add the CommonTimeManagementService.
Add a small service to the high level core set of system services to
control the configuration of the native common time service.  This
service is responsible for controlling policy regarding when the
common time service should be allowed to run, which networks it is
allowed to run on, what priority it runs at in the master election
algorithm, and so on.

Change-Id: I37308e882a0e8c4cd3e38c4f47b7c40b9150ba31
2012-02-06 18:02:33 -08:00
John Grossman
354edbc80e Implement new common_time service functionality.
Major re-factor of the common_time (formally aah_timesrv) service in
preparation for up-integration into Android master.  This work
includes bug fixes, new features, and general code cleanup.  High
points are listed below.

+ CommonClock interface has been enhanced to allow querying of many
  more low level synchronization details; mostly for debugging, but in
  theory useful to an application as well.
+ CommonTimeConfig interface has been implemented.  This allows a
  management process to configure a number of different parameters
  (many of them new) to control the behavior of the common_time
  service.  Most importantly, the time service can be bound to a
  specific network interface and should only operate on that interface
  an no others.
+ Enhance log messages to be more useful in determining what the time
  service state machine is doing and why.
+ Enhance information provided by dumpsys to provide many more details
  about the quality of time sync and the network conditions which gave
  rise to the current quality conditions.

Features, features, features....
+ Add a feature which lets the high level choose a different master
  election endpoint so that multiple time synchronization domains can
  co-exist on the same subnet (mostly to support a potential use case
  of multiple home domains in a multiple dwelling environment like a
  hotel, dormitory or apartment complex).
+ Add a feature which lets the high level assign a 64-bit group ID
  which allows partitioning of time synchronization domains even when
  the master election endpoint is shared (as it might be if broadcast
  is being used instead of multicast)
+ Add an auto-disable feature which lets the time service drop into
  network-less mode when there are no active clients of the
  common_time service in the device.  Mostly for phones, this allows
  phones to not consume network/battery resources when they don't need
  to maintain common time.
+ Add a feature which lets the high level choose the priority of the
  common_time service in the master election protocol.  This allows
  high level decisions about things like mobile vs non-mobile, wired
  ethernet vs WiFi to affect who ends up with the job of master on a
  given network.  Priority overrides at the low level also allow
  clients coming in from network-less mode to lower their effective
  priority as they join a new network so as to not disrupt any
  stable long-running timeline which may already be active on the
  network.
+ Add the ability to control some of the core parameters of the time
  sync service which effect network load (like the sync polling
  interval and the master announce interval)

Change-Id: I71af15a83cfa5ef0417b406928967fb9e02f55c6
2012-02-06 18:02:32 -08:00
John Grossman
08d7aeb048 Add Java interfaces to the common_time services.
Add classes to handling binder marshalling to and from the native
common_time interfaces (config and clock)

Change-Id: I63e0b27d357006ea200d4dd665160526290356d7
2012-02-06 18:02:26 -08:00
John Wang
18cce49e04 am 48ac0f14: Merge "Don\'t use SNR in the invalid check." into ics-mr1
* commit '48ac0f14de9be4c91bdce4e601c5eef4fd2c3123':
  Don't use SNR in the invalid check.
2012-02-06 17:02:31 -08:00
John Wang
48ac0f14de Merge "Don't use SNR in the invalid check." into ics-mr1 2012-02-06 17:00:49 -08:00
Xavier Ducrohet
3ef9b7afdd am 331bb0c3: Setup ActionBars in layoutlib the same way the platform does it. do not merge.
* commit '331bb0c393d5e2ea2485102dcddbb8c2d42654d2':
  Setup ActionBars in layoutlib the same way the platform does it. do not merge.
2012-02-06 16:42:57 -08:00
Xavier Ducrohet
331bb0c393 Setup ActionBars in layoutlib the same way the platform does it. do not merge.
Instead of using a simple ImageView for the icon, this uses the platform
layout/action_bar_home which uses a custom class to position and resize
the icon (and also supports the Up icon that we don't yet support).

This ensures that the icon is properly positionned and sized like
on devices.

(cherry picked from commit 7396348dfcfb45b7ad055f4c18cabbe5e8270d26)

Change-Id: Ifd3bc318089b70ba843519523e366e59d434e919
2012-02-06 16:40:03 -08:00
Scott Main
6eee3067cd am a9d9fa72: Merge "docs: switch from caps to initial-case for device button names" into ics-mr1
* commit 'a9d9fa723a10ae41c047a4e8eba330112d344dc8':
  docs: switch from caps to initial-case for device button names
2012-02-06 14:11:47 -08:00