msm: rpm: add RPM resource functions

The RPM resource functions are wrapper functions of msm_rpm_set/get.
For most RPM requests, the functions just call msm_rpm_set/get.  For
certain requests, the functions buffer the requests until they can
be combined with those from power management at a later time.

Change-Id: I49c609060b734a6e2cb4cac5a23541f7c4b204d5
Signed-off-by: Ai Li <aili@codeaurora.org>
msm_fb: sysfs API to turn on/off driver power

Add 'hpd' sysfs r/w; to tell driver when HPD is required

Change-Id: I777705511794668a1c7a0f16b8c61d1b3c8d4ef9
Signed-off-by: Urs Muff <umuff@codeaurora.org>
msm_fb: adding sysfs entries in probe

moving up sysfs entry creation from panel power-on to
probe, so that user-space daemon can read the cable
state before panel power is first turned on, and so
that the driver can send uevents during initial
panel power off phase.

Change-Id: I43388c37dfbf048bd0c14130b807446cb6eaacdf
Signed-off-by: Urs Muff <umuff@codeaurora.org>
msm: sdio_ctl: Change the operational sequence in Driver Initialization

sdio_ctl devices are added to the kernel before the driver is completely
initialized. This leads to the race condition of user-space operating the
device before the driver gets completely initialized. So add the device
to the kernel only after all the elements in the driver are initialized.
Also don't support any driver operation until the initialization is
complete.

Change-Id: I2cbead92fed42e73bcf367667800f7622b81ab45
Signed-off-by: Karthikeyan Ramasubramanian <kramasub@codeaurora.org>
msm_fb: display: Add MDP4 BLT mode support

Add BLT mode support to have overlay output to an intermedium
buffer before dma to display panel.

Change-Id: I14c6fd383d8d498e56620389c6a5a69768b5bffd
Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org>

overlay.mddi がちょっと怪しい
msm: synchronize gpiomux with upstream.

Now that gpiomux is in the upstream kernel, merge all the changes which
had to be made to secure acceptance into msm-2.6.35 in order to bring
the two branches into agreement.

Change-Id: I4e8c9f0c0bebfbbbcde8235397dc6d5adb9e40b8
Signed-off-by: Gregory Bean <gbean@codeaurora.org>
msm: timer: Check to see if timer is enabled before enabling tick

During hotplug, the timer is disabled during cpu_down. When the cpu's
idle thread reprograms the timer, it infinitely loops during a  check
to verify the validity of the timer count.

Change-Id: I18d8a8ff3995409da40bfc62d0005aba8d3061ea
Signed-off-by: Maheshkumar Sivasubramanian <msivasub@codeaurora.org>
msm: video: rename hdmi common code for reuse with tv-out

Rename hdmi common as external common so that it could be
reused with TV out

Change-Id: I110fb77df6db097f9f60d1845b692fda5b9a1b42
Signed-off-by: Ajay Krishnaprasad <ajayvenk@codeaurora.org>
msm_fb: display: Add early_suspend element for mipi dsi

Add a struct early_suspend element for MIPI DSI's use in the
msm_fb_data_type struct for when HAS_EARLYSUSPEND is configured.

Change-Id: I39357a9ef992881201a8a9f735b91dc6674de4aa
Signed-off-by: Michael Burr <mburr@codeaurora.org>
msm_fb: display: Don't flush img buffers unless it is cached

There is now a bit in mdp_blit_req.flags to indicate if the input
image buffer is not cached, in which case there's no reason to
flush it for DMA. The upper framework (eg. SurfaceFlinger) should
set this flag accordingly to avoid unnecessary cache flushes.

Also removed the destination cache flush since the composition engine
doesn't read back the framebuffer directly.

Change-Id: I1916c6a51c335eb0bdc0c765319b603deca82f92
Signed-off-by: Michael Burr <mburr@codeaurora.org>
msm_fb: display: Disable MDP DMA dithering

Disable MDP DMA dithering to avoid double dither effect after PPP dither

Change-Id: Ib218e6670deb2b9c0cc9cc18371495f75e66dbeb
Signed-off-by: Ravishangar Kalyanam <rkalya@codeaurora.org>
msm: video: featurize external interface code for hdmi and tv-out

Featurized HDMI specific code to use appropriate methods and
sysfs attributes.

Change-Id: I9b67ec23a6c3debfc6e65e9776d05e059c3e3cd2
Signed-off-by: Ajay Krishnaprasad <ajayvenk@codeaurora.org>
msm: msm_watchdog: Support reset in Download Mode

On a watchdog bite, the SoC reboots and starts up in download mode
On regular restart, it would reboot  without going into download mode.

Change-Id: Ic5c5b6c613d2ab359b493b260e207fecb6ffee29
Signed-off-by: Rohit Vaswani <rvaswani@codeaurora.org>
msm: smd: remove use of CONFIG_MSN_N_WAY_SMD in smd driver

CONFIG_MSN_N_WAY_SMD is used in the smd driver to conditionally declare
some edges at compile time which may not be present in all targets.
Removing this simplifies the code and does not cause any adverse
effects.

Change-Id: I46e9be8998f6110f8d09422c45f6ada0bd11ff12
Signed-off-by: Jeffrey Hugo <jhugo@codeaurora.org>
USB: msm_gadget: Use device name for creating debugfs directory

USB core is using "usb" debugfs directory for host mode.  Hence
use device name i.e "msm_hsusb" for creating debugfs directory
in MSM usb device controller driver.

Change-Id: I47a60eefc60cee526f6bb8babe3cbb4f7e90e74f
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
msm: alsa: 7x30: Fix slab corruption due to wrong memory access

Driver currently attempts to access a kmalloced memory after freeing it.
This results in slab corruption every time session ends.

Change-Id: Iacec629f1a7d2f6a09bac108152feb51540038e8
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
msm: Define memory tag for osbl region that can be reclaimed by kernel

New memory tag represents memory region that is used by early in
boot chain by bootloaders (osbl) which can be reclaimed in kernel
after bootup. Consumers of this memory region need to ensure that
this memory is used only after modem/OSBL has booted up to modem/AMSS.

Change-Id: Ib00daf196e3d12a113b5e62022763dd8c23fc25f
Signed-off-by: Ajay Dudani <adudani@codeaurora.org>
msm: clock-7x30: Correct halt bit for CSI0_VFE

Change-Id: I288adfd17cf9664fa3411fc191252f89769d09c0
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
arm: mach-msm: Indicate ScorpionMP-based systems have speculative dfetch

Without arch_has_speculative_dfetch set to 1, the cache maintenance
routines won't handle dma transfers properly, leading to problems such
as filesystem corruption. This change properly sets
arch_has_speculative_dfetch to indicate that ScorpionMP-based chips
support this.

Change-Id: I37fee5b72e97a67ea12b23bd9b284b428daf1fff
Signed-off-by: Brent DeGraaf <bdegraaf@codeaurora.org>
msm: Add cpuidle callback hooks for idle enter and exit

Add hooks into cpuidle before idle enter and after idle exit.

Change-Id: Iaeed6831eefa899ad22964038aa2b7d3c95232e3
Signed-off-by: Praveen Chidambaram <pchidamb@codeaurora.org>