cma: assign to correct variable in __iommu_alloc_buffer

When we moved to pfns in [9740ba422e "cma: use pfn instead of pages for
argument passing"], there was one place where we should have been using
a page variable instead of a pfn. Fix this.

Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
Implemented config MULTI_CPU_POLICY_LIMIT to apply policy limits on all cpus
MULTI_CPU_POLICY_LIMIT: optimizations
cpufreq: better define for scaling_min_freq_all_cpus, scaling_max_freq_all_cpus.
Implemented scaling_min_freq_cpuX, scaling_max_freq_cpuX and scaling_governor_cpuX. We have async cpu we can use different governor, freq for all cpus.
MULTI_CPU_POLICY_LIMIT: fixed a bug inside store_pcpu_scaling_governor, show_pcpu_scaling_governor, store_pcpu_scaling_freq, show_pcpu_scaling_freq functions.
CPUFREQ: Cleanups after merging with Alucard MULTI_CPU_POLICY_LIMIT
Async
CPUFREQ: Clean some white space. there are a lot of 80+ characters

Need to find time to clean them all.
HID: input: generic hidinput_input_event handler

The hidinput_input_event() callback converts input events written from
userspace into HID reports and sends them to the device. We currently
implement this in every HID transport driver, even though most of them do
the same.

This provides a generic hidinput_input_event() implementation which is
mostly copied from usbhid. It uses a delayed worker to allow multiple LED
events to be collected into a single output event.
We use the custom ->request() transport driver callback to allow drivers
to adjust the outgoing report and handle the request asynchronously. If no
custom ->request() callback is available, we fall back to the generic raw
output report handler (which is synchronous).

Drivers can still provide custom hidinput_input_event() handlers (see
logitech-dj) if the generic implementation doesn't fit their needs.

Conflicts:
	drivers/hid/hid-input.c

Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Michael Wright <michaelwr@google.com>
Change-Id: I89ccc3f675b3e8a7bbd812a6ebe12588d737cfd6
FORCE FAST CHARGE: V1.8 new fixes and options.

*Fixed fast charge to 1200 when using FFC ON, was stuck on 300ma!
*Added Ability to charge on MAX 300ma as requested by my user.
*Corrected 1500ma to 1600ma to make it more standard current.
*Rised USB max mA from 370 to 400mA. as we need more 100 for stable MTP
link from PC to Phone.
FORCE FAST CHARGE: small fix miss! we need i = 7 for 1600ma here.
alucard_hotplug: use cpufreq for getting current frequency on a cpu.
MSM Thermal: added old core control parameter ENABLED for ROM/App.

*Enabled value is a dummy. not doing any thing.
less errors from ROM thermal driver and apps.
real control is in Synapse ONLY.
*Renamed core_thermal_enabled to core_thermal

I will update Synapse control and my scripts in ramdisk for this.
FORCE FAST CHARGE: v1.9 added auto FFC on/off based on battery %

*If battery is above 95% then fast charge is set to OFF
if battery is below 95% it's enabled again if was ON/Manual before.

This should prevent full charge bugs and SODS.
ARM: 8165/1: alignment: don't break misaligned NEON load/store

The alignment fixup incorrectly decodes faulting ARM VLDn/VSTn
instructions (where the optional alignment hint is given but incorrect)
as LDR/STR, leading to register corruption. Detect these and correctly
treat them as unhandled, so that userspace gets the fault it expects.

Reported-by: Simon Hosie <simon.hosie@arm.com>
Signed-off-by: Robin Murphy <robin.murphy@arm.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
ARM: 7605/1: vmlinux.lds: Move .notes section next to the rodata

The .notes, being read-only data by nature, were placed between
read-write .data and .bss. This was harmful in case of the XIP
kernel, as being placed in the RAM range, most likely far
from the ROM address, was inflating the XIP images.

Moving the .notes at the end of the read-only section
(consisting of .text, .rodata and unwind info) fixes the problem.

Reported-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Pawel Moll <pawel.moll@arm.com>
Tested-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
ARM: KVM: enforce maximum size for identity mapped code

We're about to move to an init procedure where we rely on the
fact that the init code fits in a single page. Make sure we
align the idmap text on a vector alignment, and that the code is
not bigger than a single page.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Christoffer Dall <cdall@cs.columbia.edu>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
ARM: 8088/1: vmlinux.lds.S: drop redundant .comment

Commit 78d7530ac3 ("ARM: Clean up linker script using new linker script
macros.") modified the arm kernel linker script to use the STABS_DEBUG
macro, but left a .comment section definition. As STABS_DEBUG defines
the .comment section in an identical way, the second section definition
is redundant and can be removed.

This patch removes the redundant .comment section definition.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
ARM: 8168/1: extend __init_end to a page align address

This patch changes the __init_end address to a
page align address, so that free_initmem() can
free the whole .init section, because if the end
address is not page aligned, it will round down to
a page align address, then the tail unligned page
will not be freed.

Signed-off-by: wang <yalin.wang2010@gmail.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
Revert "G2 Panels: Ensure correct panel settings on boot"

This reverts commit 7fd2ecd36137de8210480c8648200c26fe2e70d6.

This no longer needed. as JDI/LGD panels fixed on kernel install.

Best to use STOCK LG for pannels.

Also suspected as stuck in OFF state screen.