msm: kgsl: Move the pdata structure from the public API header

The pdata structure and associated structs have no business being
in msm_kgsl.h.  Move them to include/mach/kgsl.h where they can
thrive in a non-userspace facing environment.

Change-Id: Ic0dedbadfe0d3d7d44f50c8a9a7f4cc59057d44b
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
(cherry picked from commit 914de9bfd04365038d37c749ae6abddec6cd3e00)
msm: display: Set MDP revision as 4.4 for MSM8960AB

For MSM8960AB, MDP revision is 4.4 and the same is set during
display parameter setting at reserve() call.

Change-Id: Ib34fe005f2143229fdbe648db253a7217138fdb6
Signed-off-by: Ravishangar Kalyanam <rkalya@codeaurora.org>
(cherry picked from commit 34ddee558b3cec912126c6d5c8bf7109518a64c0)
msm: Add preliminary support for MSM8960AB

Update the call sites of cpu_is_msm8960() to include an
additional check for the MSM8960AB target where
appropriate.

Change-Id: I54b1b9dccde2f21ada27bc64df02c2cb313ff1d1
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
(cherry picked from commit 9c749266c00974e4e5d4e210cae55e02301b1f4b)
mmc: msm_sdcc: remove the check for dml busy

dml busy status is supposed to be checked for during bam-to-bam mode
and not in bam-to-system mode. So removing the check for dml busy status
since the driver does not support bam-to-bam mode.

Change-Id: I1496ac441d70dd5efc831768f5ed3bfa11a3f94c
Signed-off-by: Krishna Konda <kkonda@codeaurora.org>
(cherry picked from commit 7a05d53e4aec382db2ce646805f6a69756337fdc)
ASoc: msm8960: Add msm8960AB board specific change

- GPIOs 23, 35 are used for headset mic on msm8960
- Do not configure GPIOs 23, 35 on msm8960AB target
  for headset mic, as these GIPOs are used for FAN
  external VDD_CX regulator control

Change-Id: I9320e2223fef2476c6ce7a8ccd38ef9555ebe616
Signed-off-by: Jayasena Sangaraboina <jsanga@codeaurora.org>
(cherry picked from commit 21c9f483e14dbb5b54ac5bf63f7d8711a157ebcb)
msm: kgsl: Move graphics device registration for 8960

Move all graphics device registration to one location.  Always register
the 3D core.  Register the 2D cores if they are present on the device.

Change-Id: Id92685950bb98f47725a33a931ea00eb1385d138
Signed-off-by: Carter Cooper <ccooper@codeaurora.org>
(cherry picked from commit 25555d8d29aff405bbd89076f8dd3538b8c24b80)
(cherry picked from commit 83e9dab6feacbea757e43ec54321c6a0e5acf9c1)
msm: vidc: Bus clk changes for 8960 PRO.

Assign the correct master clk ids to vidc
bus client. Without this change video init
fails.

Conflicts:

	arch/arm/mach-msm/board-8960.c

Change-Id: I88b0c6798f4c44c78d1c7428e5774f54bcb5de1a
Signed-off-by: Arun Menon <menon@codeaurora.org>
(cherry picked from commit 697e91ba3acd35d0b91503aec9811a3a52f7742d)
msm: msm_bus: Fix the number of masters for 8960 Pro

The video core master IDs on 8064 Pro are higher than
the ID values for 8960. This patch changes the max
allowed ID value to the correct number.

Change-Id: I286023c362df27272d109a822e32df6673e637ab
Signed-off-by: Gagan Mac <gmac@codeaurora.org>
(cherry picked from commit 42bb27f6410ca2ca066d0396a3d8ac4277978162)
msm: clock-8960: Disable SMMU SFPB hardware clock gating

Disable hardware clock gating for the SMMU ahb interface as
testing has shown that having it enabled leads to random lock ups
in the multimedia subsystem.

Change-Id: I9bced1aa8988e5ec2986959fa4e95cd3ccd46ef0
Signed-off-by: David Garibaldi <dgaribal@codeaurora.org>
(cherry picked from commit f69836a0bd51be3071b943e16112e69608c6d15d)
msm: clock-8960: Support alternate PLL4 clock plan

PLL4 may be running at either 491.52MHz or 393.216MHz. Detect the
rate at runtime and select the appropriate frequency tables so that
the same rates for PLL4-based clocks can be used with either
configuration.

To ensure that any PLL configuration done as part of reg_init()
takes place before the rate-detection occurs, move the reg_init()
call to the top of msm8960_clock_pre_init().

Change-Id: I547ce16334acaeee4797147e47684672d8a5bade
Signed-off-by: Matt Wagantall <mattw@codeaurora.org>
msm: clock-8960: Add support for msm8960ab clocks

Apply differences between 8960 and 8960ab, including:
1) Set PLL3 frequency to 650MHz.

2) Update frequency table and FMAX_HIGH/NOMINAL/LOW for mdp_clk,
gfx3d_clk.

3) Update reg_init, 8960_pre_init, 8960_post_init register settings.
Remove all bits marked "reserved" in 8960ab.

4) Separate lookup table into 8960 common clocks, 8960ab only clocks,
and 8960-only clocks.

Change-Id: Ie0fde5c0a289c70005622d61079ed3cddeeae095
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
msm: socinfo: Add support for detecting Krait and Krait Pass 2

Add APIs for checking whether the current CPU is Krait and
Krait Pass 2.

Change-Id: I5b28e8ae76b2df64675a6808092d792833931544
Signed-off-by: Jin Hong <jinh@codeaurora.org>
(cherry picked from commit 12b8b435bbb42f1707d2a5480bbfbd619bcdfef9)
msm: platsmp: Update Krait release sequence for 8960AB

The Krait CPU in the MSM8960AB target requires a slightly
modified sequence to bring the secondary cores out of
reset.

Change-Id: I11ee1a07a826ee982d5c57dd2347e017424a6036
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
(cherry picked from commit 121f75f4ec8a1cd05688e66d959e55d1c5c2f327)
msm: socinfo: Add support for detecting Krait Pass 3

Add an API for checking whether the current CPU is Krait
Pass 3.

Conflicts:

	arch/arm/mach-msm/include/mach/socinfo.h
	arch/arm/mach-msm/socinfo.c

Change-Id: Id6893ded88ebd83c911720bf35a9a5c9a44fa128
Signed-off-by: Joel King <joelking@codeaurora.org>
(cherry picked from commit 824bd1f08f70d90239538f1c23e50d2178546ec3)
msm: clock-8960: Add core clock for second gfx3d iommu on 8960ab

The 8960ab has two gfx3d iommus one of which was missing.
Also add a dependency on gfx3d_axi_clk for 8960ab

Change-Id: If11e6e5e6d860f27db94b6633d44b94d0ce56ed2
Signed-off-by: Joel King <joelking@codeaurora.org>
msm: acpuclock-8960ab: Add support for 8960ab

Support different L2, CPU, and system fabric configurations for
8960ab.

Conflicts:

	arch/arm/mach-msm/board-8960.c

Change-Id: Icff66cd8a977404ad2e90a85dfec7f1e6846ab13
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
(cherry picked from commit 6578e0ca8533ef23db5f36b6caa1dc303fca6da9)
msm: acpuclock-8960ab: Set power collapse rate

This line was somehow left out when initially copying the
acpuclock-8960 file over to the acpuclock-8960ab file.

Without this line, power collapse leaves the Krait PLL enabled,
causing failures upon resume.

Change-Id: I1339192d59d8b7f4135b32dcb5807bfc4dababfc
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
(cherry picked from commit 05686c3d40c93dd14ec089d9b79f9e94939b5c13)
msm: acpuclock-8960ab: Add frequencies up to 1.7 GHz.

The 8960ab application processors are able to run up to 1.7 GHz.
Update the frequency table to enable this.

Change-Id: I99f9250748f15eea2897f9d0e83c88d79d3b2ad9
Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
(cherry picked from commit c3a19dadf921a19a2f5c2f5c5ab0ae9170653b90)
msm: kgsl: Move SOC based chip ID to the board files

Move almost all of the SOC based GPU identification code out
of the KGSL driver and into the board files.  This cleans up
the GPU side and reduces our usage of the cpu_is and machine_is
macros.

Conflicts:

	arch/arm/mach-msm/board-8930-gpu.c

Change-Id: Ic0dedbad34eb034316b7baabf05aa7f8e8aa9ced
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
(cherry picked from commit 4815e9fff47da30093f4a9cec1689a4c5e2578e6)
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
Bluetooth: Add Sleep Support using GPIO for ATH3K driver.

Two additional GPIO pins are used to support sleep mechanism
between Host and Atheros BT SoC.

Change-Id: If7d49e23d285b8e416af729314cffdf7c62da136
Signed-off-by: Santosh Sajjan <ssajjan@codeaurora.org>
Signed-off-by: Ram Mohan Korukonda <rkorukon@codeaurora.org>
(cherry picked from commit 55efc7fdda4c6e067b4358c7cd246ee6ee6125fd)