FontRenderer: do not leak mIndexBufferID

This glBuffer needs to be deleted to avoid leaking
graphics memory.

CRs-Fixed: 346272
Change-Id: Ib56553fffbf88848905893b02a986765823050ad
(cherry picked from commit 8ee3ffb1c0096767311b55c509e1288901f3747f)
SurfaceTexture: Reset buffer values on disconnect.

When the surface texture client disconnects, reset the values set
for buffer width, height, transform and format. This is to ensure
that the same surface texture can be used by another client with
different parameters without any corruptions.

Change-Id: I1e158f4641d7b06cea9976ad2827c7b12c95f538
CRs-Fixed: 347382
Surfaceflinger: Add Src orientation for the layer

hwcl->transform contains the final transform, add source transform
to it, so that the source transform can be used for setting correct
orientation for Secondary display.

Change-Id: I9dd6ab9495991b01211711f55b9380a3a53cf0f0
CRs-fixed: 341691, 330719, 342199, 344308
(cherry picked from commit ec2226ef4e8c9bbf5d255d26f9677d7e36fc6ea2)
frameworks/base: surfaceflinger: Enable dither if needed

SF is checking if dithering is required but not enabling it.
Enable for layer drawing and  also for screenshot for 16bpp
framebuffer only.

CRs-fixed: 333721
(cherry picked from commit 85c02ed97b4a1d0cc343a452959570b379928d59)

Change-Id: I599fe5b9683db208c8b32a1d3d395d5203f78fd3
Handling EGL_BAD_ALLOC egl error as return from swap

Some GL apps are not closing properly espacially while
forcefully closed.Cause unnessary swap command from
GLSurfaceView and returing EGL_BAD_ALLOC as error that is
not handling in GL thread and leads to uncaught exception

CRs-fixed: 335039
(cherry picked from commit 46cc8d1f506fabd04e3e192511ab715a22ff92ea)

Change-Id: I92d08b6328a0055687ad99b9413a97ec7025e0cd
SurfaceFlinger: Return the current transform value when queried

When an application queries the transform hint,
SurfaceTexture returns the value based on the previous
queueBuffer function. When query() is called before any
queueBuffer() calls, it doesn't return the current transform.
Make sure to get the current transform from a layer
whenever query() is called.

Change-Id: Id86c931dc72285cf754cc6c77219434388fc0d69
Revert "FM radio from GB"

This reverts commit 0254a3011e5496b7fb05cfad84c0a0065a0bdbfa.
fm-frameworks: Add FM files.

Add fm frameworks and JNI files.

Change-Id: I67af0693ce394ad57ed6e6bdde23d546504714f7
fm-frameworks: Pull FM changes for audio and WAN concurrency

Pull the FM changes related to audio path and WAN concurrency

Change-Id: I437c2731b3b4db7b9bdbd7108f86ff3d4aa4869c
fm-frameworks: Exit the FM Rx listener thread, only as part of FM turn off.

Change-Id: I4bfd07563d187e069c408142f612b4f7a02b555b
fm-frameworks: Select FM Search Algorithm based on the property variable

CRs-Fixed: 314648
Change-Id: I59430cf583af5178ae54b1dd27f7b809918b555f
fm-frameworks: Add APIs to configure detection thresold parameters

Provide APIs to set and get the values of the FM search
parameters intend to improve the FM Search performance.

CRs-Fixed: 320147
Change-Id: I16136bc207251473193d732fe1fa8fa662c1f4a6
fm-frameworks: Add support for zero dwell period

Configure the Dwell period range as Zero to seven seconds

Change-Id: I5ad1d882221abd39dce8a9b8e69aafe2cc7d8495
CRs-Fixed: 322475
fm-frameworks: Enable process calibration.

Change-Id: I158b434ffeb2e91c1037e2cd3598631d105006e3
CRs-Fixed: 326567
fm-frameworks: Modify the computation of absolute frequency

Absolute frequency calculation from relative frequency and
lower band limit results in marginal variation in the value
of the exact frequency.

Change-Id: I2cfa7690e231a094cc674d09a422ff5b397f38fe
CRs-Fixed: 326007, 325078
fm-frameworks: Synchronize FM ON/OFF sequence

Prevent FM power on until previous FM power off completes

CRs-Fixed: 327151, 326855
(cherry picked from commit 3d00073605fa685bbef2665596711d3fe2ac9019)

Change-Id: I01f30cb99583863fc3f952a0c723068736e23ae0
fm-frameworks: Add support to get SINR

Add support to get the SINR value from the FM driver

CRs-Fixed: 322478
(cherry picked from commit 6231ac895216aa3622df0f69736f2246c3c82118)

Change-Id: I7ef182af6f49005a45f4e5048f825d81654a10ce
frameworks-fm: Add the delimiter for RT

Add the delimiter to the RT string and limit the RT length
to maximum allowed value

CRs-Fixed: 328036
(cherry picked from commit f61ec5af3ce2c848372260e18253c332e38c7f33)

Change-Id: I2f938b47eeb492eaaee4306a0bbaaf43abdf6e06
fm-frameworks: Implement detection threshold IOCTL's

Implement API's to get/set the signal detection parameters

CRs-Fixed: 322688
(cherry picked from commit da107ff47775560e02fa413f3984f7d9edd89401)

Change-Id: I35b9f5c949862461fd6af50fe43a18d74d764a19
fm-frameworks: Handle FM configure failure scenarios

Release the fd in case of FM configure failure

CRs-Fixed: 333035
(cherry picked from commit a28b7661abc0f903cbb43dbdea3f4d1789d17cd0)

Change-Id: Iec582661d48a68439c2ad117f2e11e77a787db57