Adding Pollux Windy device support
msm: rotator: reconcile with CAF

* remove Sony debug messages

Change-Id: I10737e17470732bb0008de73f9e039cc52ff94d0
msm: rotator: sync point support

Add MSM_ROTATOR_IOCTL_BUFFER_SYNC ioctl interface.
Rotator will create a timeline for each session at START, wait for
input fence and create released fence in this ioctl call,
signal the timeline after rotation is done.

Change-Id: I3738f8287d804ccd94e0a16ac0afb8b41b299c75
Signed-off-by: Ken Zhang <kenz@codeaurora.org>
msm: rotator: non-blocking rotate

Send request to a work queue and return right away.
Work queue will go through the commit queue to do the
rotation. wait_for_finish can be set to true to make
rotation go back to blocking.

Change-Id: Ifc2e36bd24d9681d42105f4ccbb62a8777af2a6c
Signed-off-by: Ken Zhang <kenz@codeaurora.org>
msm: rotator: Add proper checks for enabling Fast YUV

For rotator version 2.0 and above, there is support for fast
YUV which gives better rotator performance. However, there are
few constraints related to height under which fast YUV cannot be
enabled when 90 degree rotation is enabled. Make sure
to add proper checks before enabling fast YUV.

Change-Id: Iafd204a6e4ef09e1151d01d8fde35359b7c3b7a5
Signed-off-by: Padmanabhan Komanduru <pkomandu@codeaurora.org>
kgsl_pwrscale: Rework policy sysfs implementation

In the current implementation, the pwrscale policy kobj is
created when the pwrscale driver initializes.  It is then added
to the kobj hierarchy when a governor adds sysfs files.

When a governor removes sysfs files, it frees the kobj.

Then, when a new governor starts up, it attempts to add an
uninitialized kobj.  This fails.

Instead, use a constant kobj for the policy directory,
and add governor-specific attributes under it.  If a
sysfs group is given a name, all attributes in the group
will appear in a subdirectory with that name (see cpufreq
governor tuning variables).  Use this approach for our
governor tuning.

TODO (possibly in a future patch) - Rework this so the
governor attributes can be groups attached directly to
the pwrscale kobj.

Change-Id: I7b8ae6d5e690ee107be037ccaf2e737e52062feb
pm8xxx-vibrator: implement sysfs for intensity level

Node: /sys/devices/virtual/timed_output/vibrator/level
Range: 12 - 31

Change-Id: I7c2d390cb55c9d39ad9a8cc7e6eb7687832d4465
board-8064-gpu: Increase bus freq at lowest GPU frequency

1000 MBPS is too low for a 1920x1080 panel.  This results in
major UI responsiveness issues when the GPU is at 128 MHz, and
odd behavior from the GPU load measurement algorithm - low load
reported despite awful performance.  At 1500 MBPS bus speed, UI
responsiveness issues at 128 MHz disappear and the GPU will scale
properly when it needs to.

Change-Id: Iea8008d1b106ec4dd172d479d68b99f5d10b3317
Remove Qualcomm and Sony build adaptions

Change-Id: Idff4889ee9769065e78ad7b5a3c5f42e18efdbd9
kbuild: Fix gcc -x syntax

commit b1e0d8b70fa31821ebca3965f2ef8619d7c5e316 upstream.

The correct syntax for gcc -x is "gcc -x assembler", not
"gcc -xassembler". Even though the latter happens to work, the former
is what is documented in the manual page and thus what gcc wrappers
such as icecream do expect.

This isn't a cosmetic change. The missing space prevents icecream from
recognizing compilation tasks it can't handle, leading to silent kernel
miscompilations.

Besides me, credits go to Michael Matz and Dirk Mueller for
investigating the miscompilation issue and tracking it down to this
incorrect -x parameter syntax.

Signed-off-by: Jean Delvare <jdelvare@suse.de>
Acked-by: Ingo Molnar <mingo@kernel.org>
Cc: Bernhard Walle <bernhard@bwalle.de>
Cc: Michal Marek <mmarek@suse.cz>
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Michal Marek <mmarek@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
localmodconfig: Fix localyesconfig to set to 'y' not 'm'

commit 4eae518d4b01b0cbf2f0d8edb5a6f3d6245ee8fb upstream.

The kbuild target 'localyesconfig' has been same as 'localmodconfig'
since the commit 50bce3e "kconfig/streamline_config.pl: merge
local{mod,yes}config". The commit expects this script generates
different configure depending on target, but it was not yet implemented.

So I added code that sets to 'yes' when target is 'localyesconfig'.

Link: http://lkml.kernel.org/r/1349101470-12243-1-git-send-email-yuta.and@gmail.com

Signed-off-by: Yuta Ando <yuta.and@gmail.com>
Cc: linux-kbuild@vger.kernel.org
Signed-off-by: Steven Rostedt <rostedt@rostedt.homelinux.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
kbuild: make: fix if_changed when command contains backslashes

commit c353acba28fb3fa1fd05fd6b85a9fc7938330f9c upstream.

The call if_changed mechanism does not work when the command contains
backslashes.  This basically is an issue with lzo and bzip2 compressed
kernels.  The compressed binaries do not contain the uncompressed image
size, so these use size_append to append the size.  This results in
backslashes in the executed command.  With this if_changed always
detects a change in the command and rebuilds the compressed image even
if nothing has changed.

Fix this by escaping backslashes in make-cmd

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Jan Luebbe <jlu@pengutronix.de>
Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: Bernhard Walle <bernhard@bwalle.de>
Cc: Michal Marek <mmarek@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
ARM: add config option to build zImage/dtb combo

Allows a defconfig to set a default dtb to concatenate with a zImage
to create a zImage-dtb.<dtb name>

Signed-off-by: Erik Gilling <konkers@android.com>
Change-Id: I34b643b1c49228fbae88a56e46c93c478089620d
kbuild: Do not package /boot and /lib in make tar-pkg

commit fe04ddf7c2910362f3817c8156e41cbd6c0ee35d upstream.

There were reports of users destroying their Fedora installs by a kernel
tarball that replaces the /lib -> /usr/lib symlink. Let's remove the
toplevel directories from the tarball to prevent this from happening.

Reported-by: Andi Kleen <andi@firstfloor.org>
Suggested-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: Michal Marek <mmarek@suse.cz>
[bwh: Fold in commit 3ce9e53e788881da0d5f3912f80e0dd6b501f304 to avoid
 conflicts]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
usb: force 500Ma charging current on unknown chargers

- fixes charging with car chargers and unknown wall chargers

Change-Id: I7bad9447addf46aeb9ded5fc67cfac8915c5d933
perf: Treat attr.config as u64 in perf_swevent_init()

Trinity discovered that we fail to check all 64 bits of
attr.config passed by user space, resulting to out-of-bounds
access of the perf_swevent_enabled array in
sw_perf_event_destroy().

Introduced in commit b0a873ebb ("perf: Register PMU
implementations").

Signed-off-by: Tommi Rantala <tt.rantala@gmail.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: davej@redhat.com
Cc: Paul Mackerras <paulus@samba.org>
Cc: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
Link: http://lkml.kernel.org/r/1365882554-30259-1-git-send-email-tt.rantala@gmail.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
msm: audio: qdsp6v2: Add size safety check to ACDB driver

Check that the size sent by userspace is not larger
then the internal amount allowed. This protects
against overflowing the stack due to an invalid size.

Change-Id: I8230fdb00a7b57d398929e8ab0eb6587476f3db1
CRs-fixed: 470222
Signed-off-by: Ben Romberger <bromberg@codeaurora.org>
msm: audio: qdsp6v2: Fix for kernel crash during stability

- Userspace calling AYSN_READ during flush, READ_DONE ack for
  this is coming after FLUSH_DONE which is hitting BUG_ON as
  buffers are removed from in_queue/out_queue during flush.
- Fix is to avoid sending READ requests to DSP until flush
  is complete.

CRs-Fixed: 485288
Change-Id: Ia2a64471a3507b3f5565b695c40cc6dd9081930d
Signed-off-by: Deepa Madiregama <dmadireg@codeaurora.org>
ASoC: wcd9304: Include all registers to debugfs dump.

The current dumps only include a small set of registers usefull
in most use cases. Make it exhautive by including the complete
register set.

CRs-Fixed: 402905
Change-Id: I4f826dc53f3cf9c8e0d520d7f1eb872f71c357de
Signed-off-by: Asish Bhattacharya <asishb@codeaurora.org>
ASoC: msm: Add support for external EC reference point

Add mux to sound card topology with output of mux routed
to CS voice uplink front-end as way to indicate external
EC reference point. Currently, MI2S_TX is the only
AFE input port defined for this MUX.

Change-Id: I0c81c579cc01bf92e743eda0e8dee15be2a8c01f
Signed-off-by: Venkat Sudhir <vsudhir@codeaurora.org>