Monotype has released a new version of DroidNaskh. This version
has *no* changes in any of the glyphs. The change is to remove
the following tables from the .ttf files. These tables are not
used by Android and are not included in any of our other Droid
font files. These tables are not part of the TrueType Font file
specification. Removing these tables reduces the size of the
font files from ~370K to ~93K. Monotype did not bump the version
because there were no user visible changes.
ASCP and TSI0 through TSI5
Change-Id: I4f9ce63b60353e2c3b6378929fba0ed9ced456e5
Set a barrier on traversals.
Vsync is still not enabled by default in this patch so there
should be no observable effect from these changes.
Change-Id: Ie12081b95a8f1e81ed686edf747cc62f2e044b7e
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
LEFT alignment in an RTL environment had the wrong 'gravity'.
This was due to a modelling error in GridLayout which is fixed in this CL.
Also apply some very minor simplifications and refactorings following the
addition of RTL support.
Change-Id: I153bc06d3c22dcb9954e4cbdfa89625823239b89
"EffectDesc *effect = new EffectDesc(*effects[i]);" was relying on the
default copy constructor for EffectDesc, but the default copy constructor
does a member-by-member copy. This works OK for mUuid, but a member
copy of mName and mParams shares pointers. This could result in heap
corruption later on due to a double free. Changed to add an explicit
copy constructor that does a deep copy of both mName and mParams.
A malloc() and strdup() were being freed by delete, but the correct
matching API for these is free(). Fortunately our current memory runtime
implementation ignores the difference. Changed to use free().
EffectDesc and InputSourceDesc member fields were being torn down by
the code that does delete. Changed to do the tear-down in ~EffectDesc()
and ~InputSourceDesc().
Added constructor EffectDesc() with name and UUID parameters, rather
than having caller fill in the object after construction.
Made ~EffectDesc() and ~InputSourceDesc() non-virtual to save memory,
since they have no subclasses.
Change-Id: Ibb5cc2e6760d72e0c4cf537068ac4432c717bafd
Some changes in AppWidgetService were interfering with widget permissions.
Added some hidden methods in Context to communicate the requesting user
information instead of using the calling uid.
Bug: 6019296
Change-Id: I5e519fd3fbbfa5b3fcc5c297b729c671dac8e7c7
Instead of acquiring and releasing a barrier using an up/down
counter, we post a message to the queue that represents the
barrier. This is a more natural representation of the barrier
and better matches what we want to do with it: stall messages
behind the barrier in the queue while allowing messages earlier
in the queue to run as usual.
Refactored the MessageQueue a little bit to simplify the quit
logic and to better encapsulate the invariant that all
messages within the queue must have a valid target. Messages
without targets are used to represent barriers.
Bug: 5721047
Change-Id: Id297d9995474b5e3f17d24e302c58168e0a00394
Looks like not all flavors of the android build include support for
std::numeric_limits. Fix the build by using a simple macro for now.
A more elegant solution can be searched for once the build is green
again.
Change-Id: I18329cd0d26ca69de6a52df9a1c6eeb3ba063b48
Bug: 6009802
Cherry pick fcd93b72a3dde2b20fa0d8b04d3f47311b0856a1
Listen to credential storage updates and clean state when necessary.
Change-Id: I2c63e6771e9373da8b39781fdcf3d21583c4e3b2
Upintegrate the android at home TX and RX players developed in the
ICS_AAH branch.
Change-Id: I8247d3702e30d8b0e215b31a92675d8ab28dccbb
Signed-off-by: John Grossman <johngro@google.com>
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: Ic99d7b004520d7d6347842a681c0595e889b68ea
Signed-off-by: John Grossman <johngro@google.com>
Bring the Visualizer class into line with the SDK documentation by
returning ERROR_DEAD_OBJECT instead of ERROR_INVALID_OPERATION when
the Visualizer loses its binder connection to the mediaserver because
of a mediaserver restart.
Also add a new callback interface to allow clients to be
asynchronously notified in the case of server death. Right now, the
interface definition and the registration method are flagged as hidden
pending API council review/approval.
See http://b/issue?id=5717519 for details.
Change-Id: Ic15856f27ed5a950a583ac11ca81f79bd7e9b1a0
Signed-off-by: John Grossman <johngro@google.com>
Don't re-allocate buffers used by Visualizer callbacks as this causes an
unacceptable amount of GC thrash. Instead, lazily allocate the buffers and only
reallocate them when the required size changes.
See http://b/issue?id=5717519 for details.
Change-Id: Ibd157ed51f30687ce7c4ef0b4003258a484e0f5d
Signed-off-by: John Grossman <johngro@google.com>
Bring in changes to audio flinger made to support timed audio tracks
and HW master volume control.
Change-Id: Ide52d48809bdbed13acf35fd59b24637e35064ae
Signed-off-by: John Grossman <johngro@google.com>
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: I1fcd834c0286aea0df9557520693a3f42de59d69
Signed-off-by: John Grossman <johngro@google.com>
Add classes to handling binder marshalling to and from the native
common_time interfaces (config and clock)
Change-Id: I04fc429d9af27736c4f7f9b5468011ffdd4d7eaa
Signed-off-by: John Grossman <johngro@google.com>
Move the common_time service developed in the ics-aah branch back into
master.
The common_time service is a small service build to synchronize an
arbitrary timeline amongst peers on a local sub-net. While running
and configured, the service will elect a master from the set of
available devices within the subnet, define a relationship between the
common_time timeline the local time timeline (provided by the local
time HAL), and then attempt to maintain synchronization between common
and local time by controlling the frequency of the local time clock
via the HAL, or by disciplining local time in the digital domain if
the local time HAL implementation does not support HW slewing.
On its own, the native common time service will do nothing until it is
configured. The CommonTimeManagementService (running out of the
system server process) is responsible for implementing policy
regarding configuration and operation of the common_time service and
will be added in a subsequent CL.
Change-Id: I71292f9b9b1797665865689c4572c9d3a0552f64
Signed-off-by: John Grossman <johngro@google.com>