gcx: added support for rotation.

Also added GC_C_BUFFER debugger option.

Change-Id: I3eeec9ed523632a80892494d2b77a486309f4c12
Signed-off-by: Alexei Shlychkov <x0177296@ti.com>
gcx: driver optimizations.

Optimized interrupt usage.
Optimize throughput by having the main thread program
the hardware directly rather than handing off cmd
buffers to the gccmdthread.

Change-Id: I0f4eb1b3d00cc02d5bc02b9b511df782bb8fc0c5
Signed-off-by: Craig Stout <craig.stout@ti.com>
gcx: yuv support improvements.

Added UYVY and YUY2 formats for input and output.
Also fixes some issues with alignment for NV12.
Also adds destination stride check for all surfaces.

Change-Id: Ie8baa7fdba184ae6ca853499b886511869bef762
Signed-off-by: Craig Stout <craig.stout@ti.com>
gcx: process cleanup

Properly free kernel resources when userspace application gets killed

Change-Id: I00d2b7ddc6e37036ae66a16740c709b68dd0bfc7
Signed-off-by: Jack Yen <jyen@ti.com>
gcx: rotation fixes.

Fixed 90/270 degree rotation.
Fixed clipping for multi-source setup.
Fixed thread racing condition.
Also adds 8-pixel source stride check.

Change-Id: Ie7a83c738079a5930259ec520cc78970c69109f5
Signed-off-by: Alexei Shlychkov <x0177296@ti.com>
gcx: bump version to 2.1.2

Change-Id: I97c3c17e6b1cb74f110bd15c4c61bcf031c91b57
Signed-off-by: Craig Stout <craig.stout@ti.com>
OMAPDSS: DSS: SyncLost WA for wb m2m-manager mode.

This is a workaround that prevents SYNC_LOST on changing pipe
channelout from manager which was used as a source of wb to
another manager. Manager could free pipes after wb will
send SYNC message but that will start wb capture. To prevent
that we reconnect the pipe from the manager to wb and do a
dummy enabling and disabling of wb - the pipe will be freed
and capture won't start because source pipe is switched off.

Change-Id: Ib4cfbb1854c92a2e507589fbe8cf00e5cb6831ca
Signed-off-by: Artem Rudenko <x0150883@ti.com>
OMAPDSS: OMAPFB : Add support for default display scaling.

Currently it is assumed that frame buffer size
is same as default panel size. With this assumption
GFX pipeline is always presented to default display FBDev.
GFX pipeline cannot scale so we cannot have a frame
buffer which is not equal to panel size (LCD | HDMI).
Updated the current logic of omapfb to pick video pipelines
in case scaling is required for FB to be presented to default
panel.

To provide FB size option is provided via command line.
e.g
omapfb.fb_opt=0,720,1280,1,640,480
each element is [fb_ix,width,height]

Change-Id: I9e2d40bed34c5fbf2bac31668d210e0bc586bb40
Signed-off-by: Dandawate Saket <dsaket@ti.com>
Signed-off-by: Muralidhar Dixit <murali.dixit@ti.com>
OMAP4: HDMI : Support default display configuration for HDMI

Added get_resolution and get_fb_resolution function to HDMI
driver so that we can configure defaults via board files when
HDMI is default panel.

Change-Id: I36cafb4b0bd42c150c1c1a03be4607edec31b4db
Co-Author-by: Victor Kleinik <x0150886@ti.com>
Co-Author-by: Artem Rudenko <artemrudenko@ti.com>
Signed-off-by: Dandawate Saket <dsaket@ti.com>
Signed-off-by: Muralidhar Dixit <murali.dixit@ti.com>
OMAP4 : DSSCOMP : Avoid pushing content if no panel is active

Currently we push content on a blanked manager in case it is
default display. This causes a lot of logging in dsscomp call
back when we apply blank to manager.

Check added to see if any dss device is active and then only
push data to panel.

Change-Id: Idffd022e293949bfea260a01b96b8f6eff8327d3
Signed-off-by: Dandawate Saket <dsaket@ti.com>
Signed-off-by: Muralidhar Dixit <murali.dixit@ti.com>
OMAP4: OMAPFB: Dont error if display is already ON

Dont error if display state is already ON.

Change-Id: Ibad859847f2edd19cf6cd0d285461c66ed43c9a2
Signed-off-by: Dandawate Saket <dsaket@ti.com>
Signed-off-by: Muralidhar Dixit <murali.dixit@ti.com>
OMAP4: TABLET : Initialize HDMI default

Intialize HDMI defaults to 1080p timings.

Change-Id: I3e5b4fab080baa1705eb4d591a8c8da63f6c9f7c
Signed-off-by: Dandawate Saket <dsaket@ti.com>
Signed-off-by: Muralidhar Dixit <murali.dixit@ti.com>
OMAP2: correction in early params functions for android-display

Correction in early params functions in android-display.c

Change-Id: I2bef7e62cc96f75ef23690e29213c8e6d4d545ea
Signed-off-by: Muralidhar Dixit <murali.dixit@ti.com>
OMAP4: Add platform data to support HDMI default display

Adding new platform data to support HDMI default display feature.
HDMI platform data is selected if HDMI is selected as default
display in boot args.

Change-Id: Ic5968c4b293e2a1edff61490b2deab2e4af6dbcb
Signed-off-by: Muralidhar Dixit <murali.dixit@ti.com>
OMAPDSS: CEC: changing the cec switch name

Changing the CEC event to avoid conflict with HDMI
event

Change-Id: I08748e6a7b2879ffec12f009afb8b03522247309
Signed-off-by: Muralidhar Dixit <murali.dixit@ti.com>
gcx: fixed suspend issue.

Clipping was only set during init. When GC320 was shut down
in full system suspend, clipping was reset to the hardware
default (0,0)-(0,0), which caused all primitived to be clipped
after resume.

Change-Id: Ib06b2ced9460816e6d610ef329b6d9ea7a58353a
Signed-off-by: Alexei Shlychkov <x0177296@ti.com>
HACK: POWER: TWL6030_BCI: Remove backup battery sysfs attributes

TWL6030 driver registers two battery type devices,
but there is no way to mark one battery as main for Android.
So Android may use backup battery attibutes instead of main battery.

To workaround this issue /sys/class/power_supply/ should have only one
Battery type device with battery attributes.

Change-Id: I63df13f9847eeeaf8b4efd2fbe2558030caea7c8
Signed-off-by: Taras Kondratiuk <taras@ti.com>
SMC: Unlock aes_hwa_ctx lock in case of bad dma_map_sg

This release of the SMC package fixes PL310 accesses (See MSDK273
from MSHIELD)

In case of bad dma_map_sg, we silently fail. Be sure to call
spin_unlock_irqrestore before silently failing.

Change-Id: Ib6015c0710e56eae2bce341f263d62142f12ba3e
Signed-off-by: Bryan Buckley <bryan.buckley@ti.com>
Revert "OMAP4470 LPDDR interface configuration update for 466MHz"

This reverts commit 60dbf389a4408580f9200918a60d96a6eebf3919.
The patch is moved to the xloader.

Change-Id: I9bab396d290c339ef148a63bc33b04588e6f54e3
Signed-off-by: Volodymyr Mieshkov <volodymyr.mieshkov@ti.com>
OMAP4470 LPDDR interface configuration update for 466MHz

Some instability with OMAP4470 when running the DDR at 466MHz is
discovered. This instability is resolved with updated LPDDR settings:

- DLL delay should be set to 461ps:
DDR_PHY_CTRL_1_SHDW[11:4] = 0x37

- Read latency should be set to 0xB:
DDR_PHY_CTRL_1_SHDW[3:0] = 0xB

- Slew Rate should be set to “FASTEST” and Impedance Control to “Drv12”:
CONTROL_LPDDR2IOx_2[LPDDR2IO1_GR10_SR] = 0
CONTROL_LPDDR2IOx_2[LPDDR2IO1_GR10_I] = 7
where x=[1-2]

x-loader performs settings all these parameters.
The patch prevents DLL delay to be overridden by the kernel.

Change-Id: Ic7d1733f6c00941f20a2648303a0cb47761ac5df
Signed-off-by: Volodymyr Mieshkov <volodymyr.mieshkov@ti.com>