scripts: dtc: make dtb out with alignment 4 bytes

dtb size should be aligned with 4 bytes when we use appended dtb
in the zImage-dtb. Bootloader parses the dtb header from the appended dtb.
If not aligned 4 bytes, it would cause data abort due to unaligned data
access.

Change-Id: I8f80341864ceeb2dddbd23712d8193605c6fb8c3
Signed-off-by: Devin Kim <dojip.kim@lge.com>
ARM: convert build of appended dtb zImage to list of dtbs

Allow CONFIG_BUILD_ARM_APPENDED_DTB_IMAGE_NAMES to specify
a space separated list of dtbs to append to the zImage,
and name the resulting file zImage-dtb

Change-Id: I36d9108a2349bdbb373e95076dcb1417d8c7dce6
Signed-off-by: Colin Cross <ccross@android.com>

Conflicts:
	arch/arm/Kconfig
	arch/arm/Makefile
Signed-off-by: Patrick Tjin <pattjin@google.com>
gcc-wrapper: trim whitelist for gcc 4.7

With recent code and defconfig changes, the number warnings needing to
be ignored has gone done.  Update the wrapper accordingly.

Signed-off-by: Bryan Huntsman <bryanh@codeaurora.org>
script: dtc: clean generated files

Fix "make distclean" to clean up generated dtc files.

Without this patch the following files are left around:
 - dtc-lexer.lex.c
 - dtc-parser.tab.c
 - dtc-parser.tab.h

Change-Id: I0dd3b4804bd244827b02be9446f239b5bfef3d0c
Signed-off-by: Magnus Damm <damm@opensource.se>
Reviewed-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Git-commit: 4f3be1cfa8422c93271dcdb59f223f6c84c70804
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Signed-off-by: David Collins <collinsd@codeaurora.org>
dtc: import latest upstream dtc

This updates scripts/dtc to commit 317a5d9 "dtc: zero out new label
objects" from git://git.jdl.com/software/dtc.git.

This adds features such as:
* /bits/ syntax for cell data.
* Math expressions within cell data.
* The ability to delete properties or nodes.
* Support for #line directives in the input file, which allows the use of
  cpp on *.dts.
* -i command-line option (/include/ path)
* -W/-E command-line options for error/warning control.
* Removal of spew to STDOUT containing the filename being compiled.
* Many additions to the libfdt API.

Change-Id: I026548e66cb994b75fe01ee323155bf23938e43e
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Jon Loeliger <jdl@jdl.com>
Signed-off-by: Rob Herring <rob.herring@calxeda.com>
Git-commit: cd296721a9645f9f28800a072490fa15458d1fb7
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Signed-off-by: David Collins <collinsd@codeaurora.org>
dtc: fix for_each_*() to skip first object if deleted

The previous definition of for_each_*() would always include the very
first object within the list, irrespective of whether it was marked
deleted, since the deleted flag was not checked on the first object,
but only on any "next" object.

Fix for_each_*() to check the deleted flag in the loop body every
iteration to correct this.

(upstream dtc commit 1762ab42ef77db7ab2776d0d6cba3515150f518a)

Change-Id: Icfe0cd4bc7903c2ea7b85febfa154e9bcf4b552c
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Rob Herring <rob.herring@calxeda.com>
Git-commit: 205a8eb7ce713c7f1722297dd97d19dcea6f266c
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Signed-off-by: David Collins <collinsd@codeaurora.org>
ASoC: msm: qdsp6v2: amend AUXPCM DAI Driver device tree definition

By design, primary AUXPCM interface and secondary AUXPCM interface
can run concurrently and have different hardware configuration.
Current device tree definition limits primary and secondary AUXPCM
interfaces to share same hardware configuration. In addition, AUXPCM
is bi-direction audio interface. Hence, device tree definition should
not have to differentiate playback and capture DAI devices.
Amend current device tree definition and CPU DAI driver implementation
to allow concurrency and separate configuration. This change in terms
gets rid of global variables used by AUXPCM CPU DAI driver which is one
of long pending action items. Also, update machine drivers and device
tree files to reflect the new CPU DAI driver names and new device tree
structure.

Change-Id: Ifb5a2c8d594f98f07a58829801a43adb7b31ca90
CRs-fixed: 493140, 493741
Signed-off-by: Patrick Lai <plai@codeaurora.org>

Conflicts:
	sound/soc/msm/qdsp6v2/msm-dai-q6-v2.c
msm: ipc: Make the kernel-space read operation as non-blocking

Update the read operations of kernel space to be non-blocking and
return -ENOMSG when there is no message to read.

CRs-Fixed: 508370
Change-Id: I92f55d8829755078f34ff3cbe2dc9b16ed7988df
Signed-off-by: Zaheerulla Meer <zmeer@codeaurora.org>
Signed-off-by: FNU Ramendra <rramendr@codeaurora.org>
arm/dt: 8974: Add enabled interrupts to bypass list

The following interrupts were added to Bypass list
to enable XO shutdown for smart panel during static
display

hwirq: 56 ->  modem_wdog
hwirq: 70 ->  msm_iommu_pmon_nonsecure_irq
hwirq: 97 ->  msm_iommu_nonsecure_irq
hwirq: 105 -> msm_iommu_pmon_nonsecure_irq
hwirq: 181 -> wcnss_wdog
hwirq: 211 -> dwc3_otg

Signed-off-by: Badhri Jagan Sridharan <badhris@codeaurora.org>
Change-Id: I554e8090bcc8168f0f7e60f6962e55871ea44b1b
msm: clock-8974: Add PNOC request to prevent PNOC clk gating

Keep a request of 19.2Mhz for PNOC bus when APSS is not
in idle-pc.

Signed-off-by: Badhri Jagan Sridharan <badhris@codeaurora.org>
Change-Id: Ib08b92949c970bc353cca1d5a5e3155a65c02dbb
msm: acpuclock-8974: Modify L2 and DDR mapping

This helps power by voting for DDR to run at 460 MHZ
instead of 614 MHz when L2 is running at 1.04 GHz

Change-Id: I6e285de5d1806adcbedf2e526de9c733814df709
Signed-off-by: Dilip Gudlur <dgudlur@codeaurora.org>
arm/dt: msm8974: spi_qsd: Add support for clock path voting

Voting for the entire clock path (using the bus-scaling driver)
requires information about the master endpoint number. A second
new field signals the driver if vote should follow the runtime-pm
state or the application processor power state. These values
are configured in the device tree. In addition, the device-tree
binding document is updated to reflect the new fields.

Change-Id: Ie97cfd209c77fbee01a0ea4f44fa1a34377af519
Signed-off-by: Gilad Avidov <gavidov@codeaurora.org>
msm: clock-8974: Add BCR registers for GDSC-collapsible cores

The GDSC driver allows collapse of cores to be disabled
via device tree. Client drivers may still expect the core
to be reset to a clean state after calls to the GDSC APIs,
however.

Specify .bcr_reg addresses for GDSC-collapsible cores so
that the GDSC driver can assert resets to these cores in
lieu of collapsing them. This is similar to what's already
been done for venus0_vcodec0_clk for the same reason.

Change-Id: I1dfdf9562dd49eee7b38a204a063d6787fc4ce85
Signed-off-by: Matt Wagantall <mattw@codeaurora.org>
arm/dt: msm: Add bus bandwidth support to PRNG

Add device tree entries to support bus bandwidth
for PRNG driver on MSM8974, MSM8226, MSM8610.

Change-Id: Ic93a7b6e4d42f839293946d10d532a56acc94ed1
Signed-off-by: Hariprasad Dhalinarasimha <hnamgund@codeaurora.org>
ARM: dts: msm: Increase size of memory hole in memory map

Update the size of the memory hole to accomodate a larger
region for the modem image.

Change-Id: If38851e3cb4c2cf12f3b6fc11696b04d1c21bda3
Signed-off-by: Neeti Desai <neetid@codeaurora.org>
power: qpnp-bms: wake up when SoC changes while battery is full

Currently, the apps processor can be asleep when SoC drops below
the charging resume limit. Change this by setting the good_ocv and
cc_thr interrupts to be wakeable, and configuring the coulomb
counter threshold to be when SoC would change.

Change-Id: Ibefaf82570f875ca0ceabf0d2f693ba3e14ef595
Signed-off-by: Xiaozhe Shi <xiaozhes@codeaurora.org>

Conflicts:
	drivers/power/qpnp-bms.c
arm/dt: 8974: Configure FCC learning parameters

Set the Full Charge Capacity (FCC) learning parameters
and enable FCC learning.

Change-Id: I7119eb60886509b8c3a40cfea8e7907386c5088c
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>
power: qpnp-bms: Store FCC learnt data in BMS registers

BMS module supports 16 (8-bit) battery backed-up registers.
Use these registers to store the learnt FCC data. Prior to
this change, the generated FCC data was expected to be
maintained by userspace.

Every new FCC value is first interpolated to a default
temperature (this eliminates the use of storing the
temperature at which the FCC is generated). The FCC value
(in mAh) is mapped to a 8-bit value and stored accordingly.
Same encoding mechanism is used to store the charge-cycles.

Change-Id: I1f5870afbccb306cc2e54b1d539f8446c10540f6
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>

Conflicts:
	Documentation/devicetree/bindings/power/qpnp-bms.txt
	drivers/power/qpnp-bms.c