Commit graph

583310 commits

Author SHA1 Message Date
Laxminath Kasam
613aec8015 ARM: dts: msm: Fix compile warning in sdm660 audio node
Add address cells and size cells for digital audio node present
within analog codec node.

CRs-Fixed: 2000566
Change-Id: Iaf7ce40e9bcf8a1eabba0552377372fe2dd43ea3
Signed-off-by: Laxminath Kasam <lkasam@codeaurora.org>
2017-02-21 15:39:06 +05:30
Amit Nischal
e9a6b4b935 clk: qcom: Remove gcc_hmss_ahb_clk for sdm660
The gcc_hmss_ahb_clk will be controlled by RPM. Remove all
control of it from the HLOS clock driver.

Change-Id: I26525787352cb0b85937cc005afba7c37a7989ff
Signed-off-by: Amit Nischal <anischal@codeaurora.org>
2017-02-21 14:39:12 +05:30
Vlastimil Babka
28aea75c4b mm, memory hotplug: small cleanup in online_pages()
We can reuse the nid we've determined instead of repeated pfn_to_nid()
usages.  Also zone_to_nid() should be a bit cheaper in general than
pfn_to_nid().

Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Cc: Mel Gorman <mgorman@techsingularity.net>
Cc: David Rientjes <rientjes@google.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Git-commit: e888ca3545dc6823603b976e40b62af2c68b6fcc
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Change-Id: I6bdb2530fd6306ceb49022ef9cdc82b5598ebe8c
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2017-02-21 12:37:10 +05:30
Vlastimil Babka
f9d29d58eb mm, compaction: introduce kcompactd
Memory compaction can be currently performed in several contexts:

 - kswapd balancing a zone after a high-order allocation failure
 - direct compaction to satisfy a high-order allocation, including THP
   page fault attemps
 - khugepaged trying to collapse a hugepage
 - manually from /proc

The purpose of compaction is two-fold.  The obvious purpose is to
satisfy a (pending or future) high-order allocation, and is easy to
evaluate.  The other purpose is to keep overal memory fragmentation low
and help the anti-fragmentation mechanism.  The success wrt the latter
purpose is more

The current situation wrt the purposes has a few drawbacks:

 - compaction is invoked only when a high-order page or hugepage is not
   available (or manually).  This might be too late for the purposes of
   keeping memory fragmentation low.
 - direct compaction increases latency of allocations.  Again, it would
   be better if compaction was performed asynchronously to keep
   fragmentation low, before the allocation itself comes.
 - (a special case of the previous) the cost of compaction during THP
   page faults can easily offset the benefits of THP.
 - kswapd compaction appears to be complex, fragile and not working in
   some scenarios.  It could also end up compacting for a high-order
   allocation request when it should be reclaiming memory for a later
   order-0 request.

To improve the situation, we should be able to benefit from an
equivalent of kswapd, but for compaction - i.e. a background thread
which responds to fragmentation and the need for high-order allocations
(including hugepages) somewhat proactively.

One possibility is to extend the responsibilities of kswapd, which could
however complicate its design too much.  It should be better to let
kswapd handle reclaim, as order-0 allocations are often more critical
than high-order ones.

Another possibility is to extend khugepaged, but this kthread is a
single instance and tied to THP configs.

This patch goes with the option of a new set of per-node kthreads called
kcompactd, and lays the foundations, without introducing any new
tunables.  The lifecycle mimics kswapd kthreads, including the memory
hotplug hooks.

For compaction, kcompactd uses the standard compaction_suitable() and
ompact_finished() criteria and the deferred compaction functionality.
Unlike direct compaction, it uses only sync compaction, as there's no
allocation latency to minimize.

This patch doesn't yet add a call to wakeup_kcompactd.  The kswapd
compact/reclaim loop for high-order pages will be replaced by waking up
kcompactd in the next patch with the description of what's wrong with
the old approach.

Waking up of the kcompactd threads is also tied to kswapd activity and
follows these rules:
 - we don't want to affect any fastpaths, so wake up kcompactd only from
   the slowpath, as it's done for kswapd
 - if kswapd is doing reclaim, it's more important than compaction, so
   don't invoke kcompactd until kswapd goes to sleep
 - the target order used for kswapd is passed to kcompactd

Future possible future uses for kcompactd include the ability to wake up
kcompactd on demand in special situations, such as when hugepages are
not available (currently not done due to __GFP_NO_KSWAPD) or when a
fragmentation event (i.e.  __rmqueue_fallback()) occurs.  It's also
possible to perform periodic compaction with kcompactd.

[arnd@arndb.de: fix build errors with kcompactd]
[paul.gortmaker@windriver.com: don't use modular references for non modular code]
Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Cc: Mel Gorman <mgorman@techsingularity.net>
Cc: David Rientjes <rientjes@google.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Cc: Hugh Dickins <hughd@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Git-commit: 698b1b30642f1ff0ea10ef1de9745ab633031377
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Change-Id: I987ae548cba936987b8479dc02de67d0f88b9cb6
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2017-02-21 12:36:57 +05:30
Vlastimil Babka
d7e25d6390 mm, kswapd: remove bogus check of balance_classzone_idx
During work on kcompactd integration I have spotted a confusing check of
balance_classzone_idx, which I believe is bogus.

The balanced_classzone_idx is filled by balance_pgdat() as the highest
zone it attempted to balance.  This was introduced by commit dc83edd941
("mm: kswapd: use the classzone idx that kswapd was using for
sleeping_prematurely()").

The intention is that (as expressed in today's function names), the
value used for kswapd_shrink_zone() calls in balance_pgdat() is the same
as for the decisions in kswapd_try_to_sleep().

An unwanted side-effect of that commit was breaking the checks in
kswapd() whether there was another kswapd_wakeup with a tighter (=lower)
classzone_idx.  Commits 215ddd6664 ("mm: vmscan: only read
new_classzone_idx from pgdat when reclaiming successfully") and
d2ebd0f6b8 ("kswapd: avoid unnecessary rebalance after an unsuccessful
balancing") tried to fixed, but apparently introduced a bogus check that
this patch removes.

Consider zone indexes X < Y < Z, where:
- Z is the value used for the first kswapd wakeup.
- Y is returned as balanced_classzone_idx, which means zones with index higher
  than Y (including Z) were found to be unreclaimable.
- X is the value used for the second kswapd wakeup

The new wakeup with value X means that kswapd is now supposed to balance
harder all zones with index <= X.  But instead, due to Y < Z, it will go
sleep and won't read the new value X.  This is subtly wrong.

The effect of this patch is that kswapd will react better in some
situations, where e.g.  the first wakeup is for ZONE_DMA32, the second is
for ZONE_DMA, and due to unreclaimable ZONE_NORMAL.  Before this patch,
kswapd would go sleep instead of reclaiming ZONE_DMA harder.  I expect
these situations are very rare, and more value is in better
maintainability due to the removal of confusing and bogus check.

Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Joonsoo Kim <iamjoonsoo.kim@lge.com>
Cc: Mel Gorman <mgorman@techsingularity.net>
Cc: David Rientjes <rientjes@google.com>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Git-commit: 81c5857b279e6b18f6ff0d1975e80a07af542cd1
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Change-Id: If520144bb67b346a739166721137284112b9816a
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2017-02-21 12:36:28 +05:30
Jin Fu
ebfafe11f2 defconfig: msmcortex: Add ST TP configuration for QVR8998
As QVR8998 project needed, add configuration for ST touch
panel driver.

Change-Id: I5bf4d705cedb32a26bed3832dac3fe08a0f45cfa
Signed-off-by: Jin Fu <jinf@codeaurora.org>
2017-02-21 14:56:54 +08:00
Vatsal Bucha
59645729eb drivers:soc: Avoid use of uninitialized variable
While notifier de_register, we access the list which is not initialized.
Hence can result in access of uninitialized variable.
Update the loop to use correct list variable.

CRs-Fixed: 2002748
Change-Id: Ibff56477ed3fba90c8ff704ea7dbe3c472f59836
Signed-off-by: Vatsal Bucha <vbucha@codeaurora.org>
2017-02-20 21:31:48 -08:00
Jayant Shekhar
82fc7a7b26 msm: mdss: Correct mixer enumeration for sdm630
For sdm630, LM0 and LM2 layer-mixers are present.
LM1 interface mixer is removed. So, enumerate the
LM2 mixer correctly.

Change-Id: Iceff8f215ca34e95556368a13a9b0c8aeb7c2ef3
Signed-off-by: Jayant Shekhar <jshekhar@codeaurora.org>
2017-02-21 10:57:09 +05:30
Taniya Das
1a5c4d6ac3 clk: qcom: Remove mmssnoc cpu active vote clock for SDM660
There is no requirement to vote on active only clock of MMSSNOC cpu clock,
as the handoff flag for rpm clocks already takes care of the initial vote,
until the client puts across a vote.

Change-Id: I7804daa804d06ea3a7a81c4cf33156cc7324a542
Signed-off-by: Taniya Das <tdas@codeaurora.org>
2017-02-20 20:59:45 -08:00
Linux Build Service Account
c4b8f73455 Merge "ARM: dts: msm: Enable APC0/1 CPR closed-loop operation for sdm660" 2017-02-20 19:44:30 -08:00
Linux Build Service Account
14e732143d Merge "drm/msm: gpu: Return error on hw_init failure" 2017-02-20 19:44:28 -08:00
Linux Build Service Account
09191dbe4d Merge "drm/msm: Detach the MMU during msm_gpu_cleanup()" 2017-02-20 19:44:27 -08:00
Linux Build Service Account
31516ed735 Merge "msm: mdss: fix secure session power vote" 2017-02-20 19:44:27 -08:00
Linux Build Service Account
8c91258981 Merge "clk: qcom: Add support to list registers for slew PLL" 2017-02-20 19:44:26 -08:00
Linux Build Service Account
4b649675b7 Merge "certs: dm-verity: add keyring certification for verity" 2017-02-20 19:44:25 -08:00
Linux Build Service Account
56b0a1f166 Merge "ppp: defer netns reference release for ppp channel" 2017-02-20 10:08:27 -08:00
Linux Build Service Account
e7d1ccb3fa Merge "power: qcom-charger: delay ICL change reporting to parallel psy" 2017-02-20 10:08:26 -08:00
Linux Build Service Account
41bb68940b Merge "ARM: dts: msm: Enable camera for sdm630" 2017-02-20 10:08:25 -08:00
Linux Build Service Account
e4dff026df Merge "ARM: dts: msm: Add max secure video sessions for sdm660" 2017-02-20 10:08:24 -08:00
Linux Build Service Account
4d49e3647c Merge "ARM: dts: msm: add support for NO jacktype for SDM630" 2017-02-20 10:08:24 -08:00
Srikanth Uyyala
e305bc314e ARM: dts: msm: Update VFE SVS clock corner
Update the VFE SVS clock corner from 256MHz to 404MHz.
This will help use a proper AHB clock corner thereby
saving power.

Change-Id: I4adb8b2f2722fbf337cc512cec51bd57676cdeeb
Signed-off-by: Venu Yeshala <vyeshala@codeaurora.org>
2017-02-20 06:18:27 -08:00
Vijayavardhan Vennapusa
4fd545a06e USB: qusb: Add support to change TUNEX registers dynamically
Add required support to change QUSB2PHY_PORT_TUNE1/2/3/4/5 registers
dynamically for testing USB electrical complaince.

Change-Id: Id84d460c8f8dc8cdedabe3887859d6b90acf7c3f
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
2017-02-20 17:14:30 +05:30
Sarada Prasanna Garnayak
cbaa3c6555 ARM: dts: msm: Update icnss device node for sdm630
Add SMMU sid, memory base address and enable icnss
device node status for the icnss platform driver probe.

CRs-Fixed: 2008779
Change-Id: I05e48c8c450c03b119fc71c395e6456c88060c42
Signed-off-by: Sarada Prasanna Garnayak <sgarna@codeaurora.org>
2017-02-20 15:55:04 +05:30
Sharad Sangle
e0467784ad ASoC: msm: enable DAP set license logic on sdm660
Since we move to GEF implementation for Dolby post processing,
disabling DAP/DAX2 driver logic on sdm660 target except for
license validation.

CRs-Fixed: 2001077
Change-Id: Ib9e2237a5118fef2f17f745df096d4de2082f0c7
Signed-off-by: Sharad Sangle <assangle@codeaurora.org>
2017-02-20 02:24:00 -08:00
Amit Nischal
8af0bacd05 clk: qcom: Move gcc_usb3_phy_pipe_clk to branch clock
A clk_disable on gate clocks would hold a global
spinlock and it would wait for a halt_delay. In some
race conditions(due to longer delays for gate clocks)
if any other CPU would also invoke a clk_disable then
it could result in a spinlock lockup. Avoid this by
moving the gcc_usb3_phy_pipe_clk clk to branch clock.

CRs-Fixed: 2008439
Change-Id: I177349844c571964637e16a150f93c5912f7dafe
Signed-off-by: Amit Nischal <anischal@codeaurora.org>
2017-02-20 15:50:22 +05:30
Odelu Kukatla
23958fdad6 clk: qcom: Remove few multimedia clocks for sdm630
Some of the multimedia subsystem clocks are not present in sdm630,
so remove them from registering with clock framework.

Change-Id: I073dc25fa0a0665a5b9b10c4ea977767a1e286d1
Signed-off-by: Odelu Kukatla <okukatla@codeaurora.org>
2017-02-20 15:04:25 +05:30
Shaoqing Liu
1257ffc271 ARM: dts: msm: Enable SSC based sensors for QRD SDM660
Add device node for SSC sensor device for QRD SDM660.
This will create a device node to make userspace clients
read sensor related information.

Change-Id: I41f2769cad10c960961039adf177a380c69a3d56
Signed-off-by: Shaoqing Liu <shaoqingliu@codeaurora.org>
2017-02-20 17:20:35 +08:00
Rupesh Tatiya
ca3ad5ab88 Bluetooth: Enhance logging in btfm slim & audio codec drivers
Add dai name & slim port numbers for better logs for debugging. Remove
function name from pr_debug as it can be enabled by dynamic debugging.

Change-Id: If9c300e1fe22680e98dd29aadfd2bf3b8c2b5624
Signed-off-by: Rupesh Tatiya <rtatiya@codeaurora.org>
2017-02-20 00:42:10 -08:00
Hamad Kadmany
275e85d9e1 wil6210: Move dma mask setting after platform initialization
Platform specific initialization may initialize SMMU
(if available) which updates dma operations, therefore
setting of DMA mask needs to be done after platform
specific initialization.

Change-Id: I7b0e90e5e3d03816146f2f73a55dc858e03646dd
Signed-off-by: Hamad Kadmany <hkadmany@codeaurora.org>
2017-02-20 10:33:41 +02:00
Ashish Garg
4d37a6270c ARM: dts: msm: Correct vote on LDO11 for VDDIO on sdm630
On sdm630, VDDIO needs 1.8V and LDO11 votes for 1.88V
which is causing higher power numbers. Update the vote
correctly for LDO11.

Change-Id: I333dbf3077aa528376825f8fb2ff130feba9c477
Signed-off-by: Ashish Garg <ashigarg@codeaurora.org>
2017-02-20 13:06:54 +05:30
Maulik Shah
d4beaea6d5 soc: qcom: rpm_rail_stats: Add support for lpcx and lpmx rail stats
RPM has added support for lpcx and lpmx rails stats. Increase rail
buffer length to print stats for these rails.

Change-Id: I565786d847e09f325ae43e9465d744b111e7fa2c
Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
2017-02-20 13:03:48 +05:30
cyizhao
d67267d1e3 ARM: dts: msm: Enable home key for qrd sdm630
PM660 GPIO11 is used for home key on QRD sdm630 device.
Configure it to input/pull-up mode and add it to gpio-keys
device for key detection.

CRs-Fixed: 2008859
Change-Id: I3f673d925b2186069ac55ab7c9bf72fd241242c8
Signed-off-by: Yingwei Zhao <cyizhao@codeaurora.org>
2017-02-19 23:19:03 -08:00
Vinayak Menon
280a2d3683 mm: vmscan: do not pass reclaimed slab to vmpressure
During global reclaim, the nr_reclaimed passed to vmpressure includes the
pages reclaimed from slab.  But the corresponding scanned slab pages is
not passed.  There is an impact to the vmpressure values because of this.
While moving from kernel version 3.18 to 4.4, a difference is seen in the
vmpressure values for the same workload resulting in a different behaviour
of the vmpressure consumer.  One such case is of a vmpressure based
lowmemorykiller.  It is observed that the vmpressure events are received
late and less in number resulting in tasks not being killed at the right
time.  The following numbers show the impact on reclaim activity due to
the change in behaviour of lowmemorykiller on a 4GB device.  The test
launches a number of apps in sequence and repeats it multiple times.

                      v4.4           v3.18
pgpgin                163016456      145617236
pgpgout               4366220        4188004
workingset_refault    29857868       26781854
workingset_activate   6293946        5634625
pswpin                1327601        1133912
pswpout               3593842        3229602
pgalloc_dma           99520618       94402970
pgalloc_normal        104046854      98124798
pgfree                203772640      192600737
pgmajfault            2126962        1851836
pgsteal_kswapd_dma    19732899       18039462
pgsteal_kswapd_normal 19945336       17977706
pgsteal_direct_dma    206757         131376
pgsteal_direct_normal 236783         138247
pageoutrun            116622         108370
allocstall            7220           4684
compact_stall         931            856

This is a regression introduced by commit 6b4f7799c6 ("mm: vmscan:
invoke slab shrinkers from shrink_zone()").

So do not consider reclaimed slab pages for vmpressure calculation.  The
reclaimed pages from slab can be excluded because the freeing of a page by
slab shrinking depends on each slab's object population, making the cost
model (i.e.  scan:free) different from that of LRU.  Also, not every
shrinker accounts the pages it reclaims.  But ideally the pages reclaimed
from slab should be passed to vmpressure, otherwise higher vmpressure
levels can be triggered even when there is a reclaim progress.  But
accounting only the reclaimed slab pages without the scanned, and adding
something which does not fit into the cost model just adds noise to the
vmpressure values.

Fixes: 6b4f7799c6 ("mm: vmscan: invoke slab shrinkers from shrink_zone()")
Link: http://lkml.kernel.org/r/1486641577-11685-2-git-send-email-vinmenon@codeaurora.org
Acked-by: Minchan Kim <minchan@kernel.org>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Mel Gorman <mgorman@techsingularity.net>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Michal Hocko <mhocko@suse.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Vladimir Davydov <vdavydov.dev@gmail.com>
Cc: Anton Vorontsov <anton.vorontsov@linaro.org>
Cc: Shiraz Hashim <shashim@codeaurora.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Git-commit: 97a9668a428e9651a4aa3ff5d4e7e60024be2d87
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
Change-Id: If46b1cee6fd9723bebd87d76e0bb8451de05a9c1
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2017-02-20 12:12:28 +05:30
Vinayak Menon
9dd531d8e9 mm: vmpressure: fix sending wrong events on underflow
At the end of a window period, if the reclaimed pages is greater than
scanned, an unsigned underflow can result in a huge pressure value and
thus a critical event.  Reclaimed pages is found to go higher than scanned
because of the addition of reclaimed slab pages to reclaimed in
shrink_node without a corresponding increment to scanned pages.  Minchan
Kim mentioned that this can also happen in the case of a THP page where
the scanned is 1 and reclaimed could be 512.

Link: http://lkml.kernel.org/r/1486641577-11685-1-git-send-email-vinmenon@codeaurora.org
Acked-by: Minchan Kim <minchan@kernel.org>
Acked-by: Michal Hocko <mhocko@suse.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Mel Gorman <mgorman@techsingularity.net>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Rik van Riel <riel@redhat.com>
Cc: Vladimir Davydov <vdavydov.dev@gmail.com>
Cc: Anton Vorontsov <anton.vorontsov@linaro.org>
Cc: Shiraz Hashim <shashim@codeaurora.org>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Change-Id: Ic1221fa129c9b3512127537d62df7bd4a7606d24
Git-commit: 746d8d8f3ebb49a62ffcffb4b1f41cc27d020a2e
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
Signed-off-by: Vinayak Menon <vinmenon@codeaurora.org>
2017-02-20 12:12:11 +05:30
Utkarsh Saxena
1aa7b92146 msm: ipa: changes to suspend/disable for WDI 2
Adapt to latest changes to IPA micro-controller(IPA uC).

For pipe SUSPEND, IPA uC will fail in case
the pipe is not empty.

IPA driver needs to insure pipe is empty
and then issue a SUSPEND command.

For pipe DISABLE, pipe is already empty on SUSPEND,
IPA driver does not need to do ensure anything before
issuing a DISABLE command.

Change-Id: Ic0e65b671fc29583203986defada31e92065adfd
Acked-by: Mohammed Javid <mjavid@qti.qualcomm.com>
Signed-off-by: Utkarsh Saxena <usaxena@codeaurora.org>
2017-02-20 11:29:17 +05:30
Hareesh Gundu
9c6461b067 msm: kgsl: Log mmap_base value on _get_svm_area failure
_get_svm_area can fail to find available address range
from mmap_base which was adjusted by random factor.
By logging mmap_base value will help to identify
any issue with the VA randomization.

Change-Id: Ibdc3fac975adde02c30aa253b53d6533ee558161
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
2017-02-20 11:17:32 +05:30
Ashay Jaiswal
bb7e704af7 ARM: dts: msm: update enable signal polarity of SMB1351 for SDM660
Update enable signal polarity of SMB1351 as active high to make
sure STAT pin of main charger controls SMB1351.

Change-Id: I7c3fa06d59667639899ad795537ed49cb1f59e2d
Signed-off-by: Ashay Jaiswal <ashayj@codeaurora.org>
2017-02-20 09:11:21 +05:30
WANG Cong
a1e9116dac ppp: defer netns reference release for ppp channel
Matt reported that we have a NULL pointer dereference
in ppp_pernet() from ppp_connect_channel(),
i.e. pch->chan_net is NULL.

This is due to that a parallel ppp_unregister_channel()
could happen while we are in ppp_connect_channel(), during
which pch->chan_net set to NULL. Since we need a reference
to net per channel, it makes sense to sync the refcnt
with the life time of the channel, therefore we should
release this reference when we destroy it.

Fixes: 1f461dcdd296 ("ppp: take reference on channels netns")
Reported-by: Matt Bennett <Matt.Bennett@alliedtelesis.co.nz>
Cc: Paul Mackerras <paulus@samba.org>
Cc: linux-ppp@vger.kernel.org
Cc: Guillaume Nault <g.nault@alphalink.fr>
Cc: Cyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com>
Reviewed-by: Cyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Git-repo:https://source.codeaurora.org/quic/la/kernel/msm-4.4
Git-commit: 205e1e255c479f3fd77446415706463b282f94e4

Change-Id: Ic7ce3be365ebdc1505ed8ce68df981c855638a3c
Signed-off-by: Srinivasa Rao Kuppala <srkupp@codeaurora.org>
2017-02-19 15:57:19 -08:00
Jordan Crouse
efa51be2e1 drm/msm: gpu: Return error on hw_init failure
When the GPU hardware init function fails (like say, ME_INIT timed
out) return error instead of blindly continuing on. This gives us
a small chance of saving the system before it goes boom.

Change-Id: Ic0dedbad142efbc9bd93e8531b40c391ec15f557
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-02-19 16:07:56 -07:00
Jordan Crouse
41f5926f41 drm/msm: Detach the MMU during msm_gpu_cleanup()
Make sure to detach the MMU device before destroying the address
space.

Change-Id: Ic0dedbadff27fed017840a61ec5e0d55ce0c71e6
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-02-19 16:07:56 -07:00
Jordan Crouse
ffd2f3eb42 drm/msm: Support different SMMU backends for address spaces
SDE and the GPU have different requirements for the SMMU backends - the
SDE generates its own iova addresses and needs special support for DMA
buffers and the GPU does its own IOMMU operations. Add a shim layer to
aspace to break out the address generation and call the appropriate
SMMU functions. There is probably consolidation that can be done, but for
now this is the best way to deal with the two use cases.

Change-Id: Ic0dedbadc6dc03504ef7dffded18ba09fb3ef291
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-02-19 16:07:56 -07:00
Rob Clark
1de066f014 drm/msm: support multiple address spaces
We can have various combinations of 64b and 32b address space, ie. 64b
CPU but 32b display and gpu, or 64b CPU and GPU but 32b display.  So
best to decouple the device iova's from mmap offset.

Change-Id: Ic0dedbad2b36b535df3e8fb2ddddc20add592cea
Signed-off-by: Rob Clark <robdclark@gmail.com>
Git-commit: 22877bcbdacd50d076f9b2f829e6a3753aa9821f
Git-repo: https://github.com/freedreno/kernel-msm.git
[jcrouse@codeaurora.org: Fix merge conflicts, remove mdp5 due to large
infrastructure changes, compile fixes]
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
2017-02-19 16:07:56 -07:00
Linux Build Service Account
5a092dc83c Merge "msm: ipa: Do not assert if IPA FW loading fails" 2017-02-19 09:46:35 -08:00
Linux Build Service Account
3436baed84 Merge "ath10k: Add support for shadow register for WNC3990" 2017-02-19 09:46:35 -08:00
Ghanim Fodi
a13e78525f msm: ipa: Do not assert if IPA FW loading fails
Currently, IPA driver asserts if IPA FW loading
fails. Some environments do not have IPA FW
integrated and we should not crash at these cases.

CRs-fixed: 2005599
Change-Id: I78b9f2cadb8c35ab455f4514c7efc9cee4cf4542
Signed-off-by: Ghanim Fodi <gfodi@codeaurora.org>
2017-02-19 06:58:14 -08:00
Linux Build Service Account
6f0b536eb7 Merge "power: qcom-charger: fix minor bugs in parallel path" 2017-02-19 01:04:40 -08:00
Linux Build Service Account
73069045ea Merge "power: qcom-charger: add a workaround flag for QC AUTH interrupt" 2017-02-19 01:04:39 -08:00
Linux Build Service Account
3fae2f4837 Merge "ARM: dts: msm: fix the compatible string used for GFX LDO CPR for sdm630" 2017-02-19 01:04:39 -08:00
Linux Build Service Account
e7d1d81cfb Merge "ARM: dts: msm: increase the system pm levels in sdm660" 2017-02-19 01:04:38 -08:00
Linux Build Service Account
523d252348 Merge "ARM: dts: msm: Enable wil6210 device for 8998 qrd-vr" 2017-02-19 01:04:37 -08:00