summaryrefslogtreecommitdiff
path: root/include/linux (follow)
Commit message (Collapse)AuthorAge
...
* | | | iommu: Add DOMAIN_ATTR_PT_BASE_ADDR domain attributeMitchel Humpherys2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This attribute can be used to get the base address of the page tables for the given domain. This can be useful for some drivers that switch page tables around out-of-band (for example, per-process page tables managed by the GPU). Change-Id: I7c67c4c6435e5aadba129a53be532c2396dccf9c Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
* | | | iommu: add IOMMU_PRIV attributeMitchel Humpherys2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the IOMMU_PRIV attribute, which is used to indicate privileged mappings. Change-Id: If8576c09898bd7953475ab72e178d3288a763b0c Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
* | | | iommu: Add iommu_map_sg() functionOlav Haugan2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mapping and unmapping are more often than not in the critical path. map_sg allows IOMMU driver implementations to optimize the process of mapping buffers into the IOMMU page tables. Instead of mapping a buffer one page at a time and requiring potentially expensive TLB operations for each page, this function allows the driver to map all pages in one go and defer TLB maintenance until after all pages have been mapped. Additionally, the mapping operation would be faster in general since clients does not have to keep calling map API over and over again for each physically contiguous chunk of memory that needs to be mapped to a virtually contiguous region. Change-Id: I1f3dd2c3cf67b3db40ee1793580d6af5fec1247d Signed-off-by: Olav Haugan <ohaugan@codeaurora.org> Signed-off-by: Joerg Roedel <jroedel@suse.de> Git-commit: 315786ebbf4ad6552b6fd8e0e7b2ea220fcbfdbd Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git [mitchelh: fix existing callers and implementations of iommu_{map,unmap}_range to match the new function names and APIs, maintaining stubs for the old API so that out-of-tree modules can continue to compile] Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
* | | | iommu/arm-smmu: add .domain_{set,get}_attr for coherent walk controlMitchel Humpherys2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Under certain conditions coherent hardware translation table walks can result in degraded performance. Add a new domain attribute to disable/enable this feature in generic code along with the domain attribute setter and getter to handle it in the ARM SMMU driver. Change-Id: Ic9812d5047af19093ec2db8246a7f0f9ccb626ab Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
* | | | iommu: Sync files for kernel upgradePatrick Daly2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reset the following files: arm-smmu.c iommu.c include/linux/iommu.h include/trace/events/iommu.h to the git merge base between 3.18 and 4.4: b2776bf7149bddd1f4161f14f79520f17fc1d71d Change-Id: I9aa58e08125e3a72d1e9742e26d4a6fab34b0ed5 Signed-off-by: Patrick Daly <pdaly@codeaurora.org>
* | | | thermal: qpnp-adc-tm: Enable VADC_TMSiddartha Mohanadoss2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This snapshot is taken as of msm-3.18 commit dbdb6776f (Merge "msm: camera: Add dummy sub module in sensor pipeline") Fixup compilation to support int type for temperature value as part of thermal ops API upgrade. Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>
* | | | dma-mapping: Exclude remap functions when arch does not use DMANaveen Ramaraj2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The commit 'a106f65b("dma-mapping: Add dma_remap functions")' is defined remap functions for ARM arch only, so it will break other architecture compilation. So remap functions are excluded, if arch is not using DMA. Change-Id: Id39fcbac74f30a0ab1b3ce0c780460017ea189e5 Signed-off-by: Naveen Ramaraj <nramaraj@codeaurora.org> Signed-off-by: Lingutla Chandrasekhar <clingutla@codeaurora.org> Signed-off-by: Jeevan Shriram <jshriram@codeaurora.org>
* | | | slimbus: Add snapshot of slimbus driverGirish Mahadevan2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add snapshot of slimbus driver from msm-3.18 branch. Baseline: e70ad0cd5efdd9dc91a77dcdac31d6132e1315c1 Change-Id: I82f8f91596d2c3e9ef111e26c80298d990f6c193 Signed-off-by: Girish Mahadevan <girishm@codeaurora.org>
* | | | tty: serial: msm_hs: Add snapshot of msm_hs uart driversGirish Mahadevan2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Snapshot of msm_hs uart driver from msm-3.18. Baseline: e70ad0cd5efdd9dc91a77dcdac31d6132e1315c1 Change-Id: I977d80142c2cf8df89810f1c38d523d53371cc46 Signed-off-by: Girish Mahadevan <girishm@codeaurora.org>
* | | | i2c: Add snapshot of i2c-msm-v2 driverGirish Mahadevan2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds a snapshot of the i2c-msm-v2 driver from kernel-3.18. Kernel-3.18 baseline: e70ad0cd5efdd9dc91a77dcdac31d6132e1315c1 Change-Id: I392a1761ecc324c4a229caf112b1dc4c32a3b9bf Signed-off-by: Girish Mahadevan <girishm@codeaurora.org>
* | | | spi: Add snapshot of SPI QSD driverGirish Mahadevan2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change adds a snapshot of SPI QSD driver from the 3.18 branch. kernel-3.18 baseline: e70ad0cd5efdd9dc91a77dcdac31d6132e1315c1 Change-Id: I6e2a4be429a2681603a12e5ecb6853582cd3ffbe Signed-off-by: Girish Mahadevan <girishm@codeaurora.org>
* | | | thermal: tsens: Enable TSENSSiddartha Mohanadoss2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This snapshot is taken as of msm-3.18 commit dbdb6776f (Merge "msm: camera: Add dummy sub module in sensor pipeline") Commit 0b46b8a7 (clocksource: arch_timer: Fix code to use physical timers when requested) introduces the use of physical counters and requires clients to use api arch_counter_get_cntvct(). Accordingly update tsens_poll() to the new API to prevent a BUG_ON() during bootup. Fixup TSENS to use supported int type for temperature value. Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>
* | | | qcom-charger: batterydata-lib: fix compilation issueNicholas Troast2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | batterydata-lib.h limits function declarations to certain CONFIGs and provides stub function definitions for everyone else. Remove the function defintions and provide function declarations to everyone. Signed-off-by: Nicholas Troast <ntroast@codeaurora.org>
* | | | hwmon: Enable EPM driverSiddartha Mohanadoss2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This snapshot is taken as of msm-3.18 commit dbdb6776f (Merge "msm: camera: Add dummy sub module in sensor pipeline") Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>
* | | | ARM64: smp: implement arch_trigger_all_cpus_backtrace using IPIRohit Vaswani2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since ARM64 doesn't have an NMI, send an IPI to all other CPUs (current cpu prints the stack directly) to capture a backtrace. Change-Id: Ib90494123205b3bbaa0b244ccde6c7e40a560199 Signed-off-by: Rohit Vaswani <rvaswani@codeaurora.org> [satyap: trivial merge conflict resolution & compilation fixes] Signed-off-by: Satya Durga Srinivasu Prabhala <satyap@codeaurora.org>
* | | | UBSAN: run-time undefined behavior sanity checkerAndrey Ryabinin2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | UBSAN uses compile-time instrumentation to catch undefined behavior (UB). Compiler inserts code that perform certain kinds of checks before operations that could cause UB. If check fails (i.e. UB detected) __ubsan_handle_* function called to print error message. So the most of the work is done by compiler. This patch just implements ubsan handlers printing errors. GCC has this capability since 4.9.x [1] (see -fsanitize=undefined option and its suboptions). However GCC 5.x has more checkers implemented [2]. Article [3] has a bit more details about UBSAN in the GCC. [1] - https://gcc.gnu.org/onlinedocs/gcc-4.9.0/gcc/Debugging-Options.html [2] - https://gcc.gnu.org/onlinedocs/gcc/Debugging-Options.html [3] - http://developerblog.redhat.com/2014/10/16/gcc-undefined-behavior-sanitizer-ubsan/ Issues which UBSAN has found thus far are: Found bugs: * out-of-bounds access - 97840cb67ff5 ("netfilter: nfnetlink: fix insufficient validation in nfnetlink_bind") undefined shifts: * d48458d4a768 ("jbd2: use a better hash function for the revoke table") * 10632008b9e1 ("clockevents: Prevent shift out of bounds") * 'x << -1' shift in ext4 - http://lkml.kernel.org/r/<5444EF21.8020501@samsung.com> * undefined rol32(0) - http://lkml.kernel.org/r/<1449198241-20654-1-git-send-email-sasha.levin@oracle.com> * undefined dirty_ratelimit calculation - http://lkml.kernel.org/r/<566594E2.3050306@odin.com> * undefined roundown_pow_of_two(0) - http://lkml.kernel.org/r/<1449156616-11474-1-git-send-email-sasha.levin@oracle.com> * [WONTFIX] undefined shift in __bpf_prog_run - http://lkml.kernel.org/r/<CACT4Y+ZxoR3UjLgcNdUm4fECLMx2VdtfrENMtRRCdgHB2n0bJA@mail.gmail.com> WONTFIX here because it should be fixed in bpf program, not in kernel. signed overflows: * 32a8df4e0b33f ("sched: Fix odd values in effective_load() calculations") * mul overflow in ntp - http://lkml.kernel.org/r/<1449175608-1146-1-git-send-email-sasha.levin@oracle.com> * incorrect conversion into rtc_time in rtc_time64_to_tm() - http://lkml.kernel.org/r/<1449187944-11730-1-git-send-email-sasha.levin@oracle.com> * unvalidated timespec in io_getevents() - http://lkml.kernel.org/r/<CACT4Y+bBxVYLQ6LtOKrKtnLthqLHcw-BMp3aqP3mjdAvr9FULQ@mail.gmail.com> * [NOTABUG] signed overflow in ktime_add_safe() - http://lkml.kernel.org/r/<CACT4Y+aJ4muRnWxsUe1CMnA6P8nooO33kwG-c8YZg=0Xc8rJqw@mail.gmail.com> [akpm@linux-foundation.org: fix unused local warning] [akpm@linux-foundation.org: fix __int128 build woes] Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Sasha Levin <sasha.levin@oracle.com> Cc: Randy Dunlap <rdunlap@infradead.org> Cc: Rasmus Villemoes <linux@rasmusvillemoes.dk> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Michal Marek <mmarek@suse.cz> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@redhat.com> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Yury Gribov <y.gribov@samsung.com> Cc: Dmitry Vyukov <dvyukov@google.com> Cc: Konstantin Khlebnikov <koct9i@gmail.com> Cc: Kostya Serebryany <kcc@google.com> Cc: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Git-repo: https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/ Git-commit: c6d308534aef6c99904bf5862066360ae067abc4 [tsoni@codeaurora.org: trivial merge conflict resolution] CRs-Fixed: 969533 Change-Id: I048b9936b1120e0d375b7932c59de78d8ef8f411 Signed-off-by: Trilok Soni <tsoni@codeaurora.org> [satyap@codeaurora.org: trivial merge conflict resolution] Signed-off-by: Satya Durga Srinivasu Prabhala <satyap@codeaurora.org>
* | | | net/ipv6/addrconf: IPv6 tethering enhancementTianyi Gou2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added new procfs flag to toggle the automatic addition of prefix routes on a per device basis. The new flag is accept_ra_prefix_route. Defaults to 1 as to not break existing behavior. CRs-Fixed: 435320 Change-Id: If25493890c7531c27f5b2c4855afebbbbf5d072a Acked-by: Harout S. Hedeshian <harouth@qti.qualcomm.com> Signed-off-by: Tianyi Gou <tgou@codeaurora.org> [subashab@codeaurora.org: resolve trivial merge conflicts] Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
* | | | net: add a per-cpu counter for the number of frames coalesced in GROHarout Hedeshian2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A low cost method of determining GRO statistics is required. This change introduces a new counter which tracks whenever GRO coalesces ingress packets. The counter is per-CPU and exposed in /proc/net/softnet_stat as the last column of data. No user space impact is expected as a result of this change. However, this change should be reverted if legacy tools have problems with the new column in softnet_stat. Change-Id: I05965c0cb150947935d5977884cc4d583b37131d Signed-off-by: Harout Hedeshian <harouth@codeaurora.org> [subashab@codeaurora.org: resolve trivial merge conflicts] Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
* | | | Revert "net, lib: kill arch_fast_hash library bits"Rohit Vaswani2016-03-22
| | | | | | | | | | | | | | | | This reverts commit 0cb6c969ed9de43687abdfc63714b6fe4385d2fc.
* | | | msm: pcie: add SMMU support to calculate SID for PCIe EPTony Truong2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SMMU requires PCIe to provide a SID for each of its endpoint so that the endpoint can successful transaction on the bus. This change adds the support for PCIe bus driver to calculate a SID for its endpoint and give it to the SMMU driver. Change-Id: I52099bbfed0a38c75b0277b0f58f45f6e6559695 Signed-off-by: Tony Truong <truong@codeaurora.org>
* | | | msm: pcie: add PCIe bus driver snapshotTony Truong2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This PCIe bus driver snapshot is taken as of msm-3.10 commit: 803998b (Merge "ASoC: wcd: don't set autozeroing for conga") This change adds the PCIe bus driver and its dependecies from msm-3.10 to msm-3.14. All the files are as is from msm-3.10. No additional changes were made. Change-Id: Ia1a2d0eea0cc87c16357c95bfcc4df72e910cd34 Signed-off-by: Tony Truong <truong@codeaurora.org>
* | | | rtc: alarm: Add power-on alarm featureMao Jinlong2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Android does not support powering-up the phone through alarm. Set rtc alarm in timerfd to power-up the phone after alarm expiration. Change-Id: I781389c658fb00ba7f0ce089d706c10f202a7dc6 Signed-off-by: Mao Jinlong <c_jmao@codeaurora.org>
* | | | soc: qcom: rq_stats: add snapshot of run queue stats driverMatt Wagantall2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a snapshot of the run queue stats driver as of msm-3.10 commit 4bf320bd ("Merge "ASoC: msm8952: set async flag for 8952 dailink"") Resolve checkpatch warnings in the process, notably the replacement of sscanf with kstrtouint. Change-Id: I7e2f98223677e6477df114ffe770c0740ed37de9 Signed-off-by: Matt Wagantall <mattw@codeaurora.org> Signed-off-by: Abhimanyu Kapur <abhimany@codeaurora.org>
* | | | platform: msm: Add snapshot of the SPS/BAM driverYan He2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add the MSM SPS (Smart Peripheral Switch) driver. SPS may be used as a DMA engine to move data in either Peripheral-to- Peripheral (a.k.a. BAM-to-BAM) mode or Peripheral-to-Memory (a.k.a BAM-System) mode. This snapshot is taken as of msm-3.18 commit 132e1315c1 Change-Id: I7ec9781c3b608b9ee0fffdf7ba3e1b33bfa4dfcd Signed-off-by: Yan He <yanhe@codeaurora.org>
* | | | soc: qcom: Snapshot of thermal/LMH driversMahesh Sivasubramanian2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This snapshot is taken as of msm-3.18 commit e70ad0c (Promotion of kernel.lnx.3.18-151201.) Include necessary thermal_core changes to convert long to int inline with upstream kernel changes. Change-Id: I642b666518fe72385794b743989a0f5e5120ec03 Conflicts: drivers/thermal/Makefile
* | | | kobject: increase number of kobject uevent pointers to 64Subbaraman Narayanamurthy2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Power supply framework uses uevents to notify the power supply change events to the userspace. Some power supplies have their properties increasing thus overflowing the number of kobject uevent pointers, triggering warning shown below. [ 10.577545] WARNING: CPU: 3 PID: 406 at kernel/lib/kobject_uevent.c:393 add_uevent_var+0xc0/0x100() [ 10.589680] add_uevent_var: too many keys [ 10.593809] Modules linked in: [ 10.596686] CPU: 3 PID: 406 Comm: kworker/3:2 Tainted: G W 3.18.20-g5e99605-00057-gd18285f #603 [ 10.606373] Hardware name: Qualcomm Technologies, Inc. MSM 8996 v3 + PMI8996 MTP (DT) [ 10.614188] Workqueue: events power_supply_changed_work [ 10.619366] Call trace: [ 10.621803] [<ffffffc00008881c>] dump_backtrace+0x0/0x130 [ 10.627175] [<ffffffc00008895c>] show_stack+0x10/0x1c [ 10.632237] [<ffffffc000cc4d00>] dump_stack+0x74/0xb8 [ 10.637253] [<ffffffc0000a0fec>] warn_slowpath_common+0x90/0xb8 [ 10.643170] [<ffffffc0000a1060>] warn_slowpath_fmt+0x4c/0x58 [ 10.648814] [<ffffffc00031121c>] add_uevent_var+0xbc/0x100 [ 10.654259] [<ffffffc0003116f8>] kobject_uevent_env+0x498/0x5a8 [ 10.660185] [<ffffffc000311814>] kobject_uevent+0xc/0x18 [ 10.665457] [<ffffffc0007fd3c0>] power_supply_changed_work+0xb0/0xf0 [ 10.671830] [<ffffffc0000b617c>] process_one_work+0x23c/0x3f4 [ 10.677529] [<ffffffc0000b7338>] worker_thread+0x280/0x3a8 [ 10.683017] [<ffffffc0000bb384>] kthread+0xe0/0xec Fix this warning by increasing the number of kobject uevent pointers from 32 to 64. CRs-Fixed: 971954 Change-Id: Ide942d25006abd36ba7be945be397a535e91d970 Signed-off-by: Subbaraman Narayanamurthy <subbaram@codeaurora.org>
* | | | thermal-core: Add separate threads for sysfs notifyShiju Mathew2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add separate threads for sysfs notify. This is required so that any thermal trip is not blocked while handling sysfs notify. Change-Id: Ifee206c29fd1b3c226a342b7f048250d5062397e Signed-off-by: Shiju Mathew <shijum@codeaurora.org> [imaund@codeaurora.org: Resolved context conflicts and updated a call of INIT_COMPLETION to reinit_completion] Signed-off-by: Ian Maund <imaund@codeaurora.org>
* | | | thermal-core: Add API to get temperatureArchana Sathyakumar2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, there is no API to query the current temperature in sensor framework. Add a generic API to get it. Change-Id: I038e9a118e77eb6a3599b7d45a0cc8757990d2ef Signed-off-by: Archana Sathyakumar <asathyak@codeaurora.org> Conflicts: include/linux/thermal.h
* | | | thermal: Add Support for enabling and disabling tsens tripRam Chandrasekar2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add new API to enable or disable the kernel client's trip threshold request. The enable or disable trip threshold requests from different kernel clients and userspace client will activate/deactivate the corresponding clients threshold request. Modify thermal sys framework to include only the active thresholds from clients to determine the current trip thresholds for tsens. CRs-Fixed: 561775 Change-Id: I304ac00daa8a0a1a68b60153c29ee6cb5c3507b1 Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org> [joshc: drop msm_thermal chunk] Signed-off-by: Josh Cartwright <joshc@codeaurora.org>
* | | | thermal: Fix sensor thresholds not accounted correctlyPraveen Chidambaram2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sensor threshold min and max are calculated to be binding around the current temp, but they fail if there no thresholds available with the min < curr_temp and the max > curr_temp. Fix negative temperatures handling. Change-Id: I124d2a9249f705d41469b8e0efffe2dfdf05e292 Signed-off-by: Praveen Chidambaram <pchidamb@codeaurora.org>
* | | | thermal: Add sensor API to allow any driver to set thresholdsPraveen Chidambaram2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sensor API allow drivers to set min or max thresholds and get notified when the corresponding sensor crosses these thresholds. The sensor API, uses the THERMAL_TRIP_CONFIGURABLE_HI and THERMAL_TRIP_CONFIGURABLE_LOW, to set the threshold. The existing sysfs interfaces will not be affected by the newly added API. Change-Id: I85d2ae132fc3b7b6d157faf0a7390e31fdc7e6da Signed-off-by: Praveen Chidambaram <pchidamb@codeaurora.org> Conflicts: include/linux/thermal.h
* | | | thermal: tsens: TSENS driver fixupsSiddartha Mohanadoss2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add TSENS Thermal driver. Include support to activate a trip type and mode. This snapshot is taken as of msm-3.14 commit 3bc54cf86b (Merge "msm: camera: Add dummy sub module in sensor pipeline") Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org> Conflicts: drivers/thermal/Kconfig drivers/thermal/Makefile include/linux/thermal.h Change-Id: Ie8a089afc0cf9e45ac000dff425a3e6206c1b9b1
* | | | soc: qcom: Add snapshot of QMIKarthikeyan Ramasubramanian2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This snapshot is taken as of msm-3.18 commit e70ad0cd (Promotion of kernel.lnx.3.18-151201.) Signed-off-by: Karthikeyan Ramasubramanian <kramasub@codeaurora.org>
* | | | net: ipc_router: Add snapshot of IPC RouterKarthikeyan Ramasubramanian2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This snapshot is taken as of msm-3.18 commit e70ad0cd (Promotion of kernel.lnx.3.18-151201.) Signed-off-by: Karthikeyan Ramasubramanian <kramasub@codeaurora.org>
* | | | firmware_class: Include a size argument in unmap_fw_memVikram Mulukutla2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some implementations may need to know the size of a region allocated by map_fw_mem in the context of the unmap_fw_mem callback. Add this as an argument to the callback signature. Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org>
* | | | firmware_class: Allow private data in [unmap|map]_fw_memVikram Mulukutla2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some callers of request_firmware_direct may need additional context to be able to map firmware memory. Allow private data to be passed in with request_firmware_direct, and send this data along with the [unmap|map]_fw_mem callbacks. Change-Id: I05a15eb46cc663a4476b784e30e80182a28e10c3 Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org> [joshc: dropped PIL portions, fixed trivial conflict in firmware.h due to API rename] Signed-off-by: Josh Cartwright <joshc@codeaurora.org> [vmulukut: adjusted for upstream merge conflicts] Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org>
* | | | firmware_class: Introduce the request_firmware_direct APIVikram Mulukutla2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On devices with low memory, using request_firmware on rather large firmware images results in a memory usage penalty that might be unaffordable. Introduce a new API that allows the firmware image to be directly loaded to a destination address without using any intermediate buffer. Change-Id: I51b55dd9044ea669e2126a3f908028850bf76325 Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org> [joshc: renamed request_firmware_direct to request_firmware_into_buf, avoiding namespace conflict] Signed-off-by: Josh Cartwright <joshc@codeaurora.org> [vmulukut: upstream merge conflict fixups] Signed-off-by: Vikram Mulukutla <markivx@codeaurora.org> [dkeitel: upstream merge conflict fixups] Signed-off-by: David Keitel <dkeitel@codeaurora.org>
* | | | cpuidle: lpm-levels: Fixes for clockevents_notifyMahesh Sivasubramanian2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The use of clockevents_notify is deprcated and targeted APIs are used instead of the clockevents_notify callbacks. Switch broadcast timer notifications to tick_broadcast_enter and tick_broadcast_exit. Change-Id: I3441873eb4009b105db04f4a18d28ae9ccd07e95
* | | | cpu_pm: Add level to the cluster pm notificationMurali Nalajala2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cluster pm notifications without level information increases difficulty and complexity for the registered drivers to figure out when the last coherency level is going into power collapse. Send notifications with level information that allows the registered drivers to easily determine the cluster level that is going in/out of power collapse. There is an issue with this implementation. GIC driver saves and restores the distributed registers as part of cluster notifications. On newer platforms there are multiple cluster levels are defined (e.g l2, cci etc). These cluster level notofications can happen independently. On MSM platforms GIC is still active while the cluster sleeps in idle, causing the GIC state to be overwritten with an incorrect previous state of the interrupts. This leads to a system hang. Do not save and restore on any L2 and higher cache coherency level sleep entry and exit. Change-Id: I31918d6383f19e80fe3b064cfaf0b55e16b97eb6 Signed-off-by: Archana Sathyakumar <asathyak@codeaurora.org> Signed-off-by: Murali Nalajala <mnalajal@codeaurora.org> Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org> Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
* | | | soc: qcom: idle: Snapshot of idle/sleep driver as of msm-3.18Mahesh Sivasubramanian2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a snapshot of the Sleep driver and realted functionality as of e70ad0cd5efdd9dc91a77dcdac31d6132e1315c1 on msm-3.18 branch Change-Id: I98fec26849898c5c66abbb1b094439780c23964d
* | | | soc: qcom: mpm-of: Add gpio_arch_extn supportMahesh Sivasubramanian2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To wake up from system sleep, the MPM driver needs to keep track of enabled GPIO interrupts. Add gpio_arch_extn to support monitoring of GPIO interrupts Change-Id: If97f566e11eaab452e4b55db1a05e5457f1a8d3f Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
* | | | Reverting "irqchip: gic: Drop support for gic_arch_extn"Marc Zyngier2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MSM chipsets rely on arch_extn to get the necessary functionality. Add them until a upstream solution can be arrived at. Change-Id: I773a3e82ca81b1c49cf2581f5288cacaeb6c6db0 Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
* | | | irqchip: msm: Add snaphot of msm irq driverAbhimanyu Kapur2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Snapshot the msm irq driver as of msm-3.14 commit: 3bc54cf86bdc7affa7cd4bf7faa3c57fe8f8819d (Merge "msm: camera: Add dummy sub module in sensor pipeline") Signed-off-by: Abhimanyu Kapur <abhimany@codeaurora.org> Conflicts: drivers/irqchip/Kconfig drivers/irqchip/Makefile Change-Id: Idf5284906af960fe03dcf881df1b57149c8e6ad8
* | | | usb: dwc3: Add support for POR upon composition switchHemant Kumar2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Composition switch to GSI transport based composition from another GSI transport based composition requires power on reset of USB controller to synchronize operation with USB wrapper for GSI. Specifically GSI_EN bit cannot be cleared without performing usb controller reset. Hence introduce gadget restart operation to simulate vbus off and vbus on and perform this operation from gsi bind config. Change-Id: Ie4695807c73c2d14c0d9e17c486f34a90fd93ddb Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
* | | | usb: dwc3: Adjust TX FIFO allocationJack Pham2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Optimize the dwc3_gadget_resize_tx_fifos() function to better allocate the per-endpoint FIFOs depending on a number of factors: - super- or non-super speed - bulk/isoc with bursting - reduced RAM (when QDSS uses some internal RAM) - endpoint enabled in composition Signed-off-by: Jack Pham <jackp@codeaurora.org>
* | | | usb: gadget: Add udc_priv member to struct usb_requestJack Pham2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This member is used to store additional private flags for BAM-enabled functions to pass information to the UDC. Signed-off-by: Jack Pham <jackp@codeaurora.org>
* | | | USB: phy: Add support to invoke DP and DM sourcing and pulsingMayank Rana2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change adds support for sourcing and pulsig with DP/DM using QUSB PHY. This change uses POWER_SUPPLY_PROP_DP_DM power supply property with different values to achieve the same. This change is a cherry-pick of msm-3.18 commit 55b93e2506d5399b1b0ee4a1b173168fb8026548 ("USB: Add support to invoke DP and DM sourcing and pulsing") with only the change from include/linux/usb/phy.h Signed-off-by: Mayank Rana <mrana@codeaurora.org> Signed-off-by: Jack Pham <jackp@codeaurora.org>
* | | | usb: phy: Add new OTG state OTG_STATE_B_SUSPENDEDHemant Kumar2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This state is used to handle:- - Bus suspend followed by cable disconnect: pm usage count is incremented upon cable connect. Upon bus suspend, suspend interrupt kicks in otg state machine which moves device state to OTG_STATE_B_SUSPENDED from OTG_STATE_B_PERIPHERAL and decrements pm usage count. Upon cable unplug additional decrement of pm usage count is prevented. This state also takes care the handling of cable unplug followed by bus suspend interrupt. - Host initiated resume after bus suspend: Being in OTG_STATE_B_SUSPENDED after bus suspend, upon host initiated resume, wakeup interrupt kicks in otg state machine which moves device to OTG_STATE_B_PERIPHERAL state by incrementing pm usage count. - PC reboot with cable plugged in: After PC shutdown device goes to OTG_STATE_B_SUSPENDED state. After PC start power event irq thread kicks in otg state machine to move device to OTG_STATE_B_PERIPHERAL state and increments pm usage count. - Composition switch after bus suspend: dwc3_gadget_pullup() kicks in otg state machine to move device state from OTG_STATE_B_SUSPENDED to OTG_STATE_B_PERIPHERAL and increments pm usage count to prevent runtime suspend during device enumeration. Also, remove pm_runtime_set_active() which sets the PM runtime stauts as active to avoid pm_runtime_get_sync() failures which explicitly checks for runtime pm status. For example, if status is active, pm_runtime_get_sync() will just increments the counter without actually resuming the device. Change-Id: Id33b81911ef3894a00802b3e553840b9447f6269 Signed-off-by: Hemant Kumar <hemantk@codeaurora.org> [jackp@codeaurora.org: cherry-pick only phy.h and common.c] Signed-off-by: Jack Pham <jackp@codeaurora.org>
* | | | usb: phy: Expose new PHY callback for performing PHY resetMaya Erez2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a new PHY callback for performing PHY reset, which is required by some targets during their initialization sequence. As usb_phy_reset name was already in use by local msm PHY APIs, change the previous usb_phy_reset to msm_usb_phy_reset. Change-Id: Ieb5099d12e107c123d8889058aa564d0b091d6f9 Signed-off-by: Maya Erez <merez@codeaurora.org>
* | | | usb: dwc3: msm: Add snapshot of DWC3 MSM driversJack Pham2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add dwc3-msm.c and associated driver files. Note these are based on the downstream implementation and will coexist (for the time being) with dwc3-qcom glue driver until they can eventually be merged. This snapshot is taken as of msm-3.18 commit a3883c356869 (Merge "input: touchscreen: correct condition checks in ITE tech touch driver") Signed-off-by: Jack Pham <jackp@codeaurora.org>